Glenn Linderman <v+pyt...@g.nevcal.com> added the comment:

In msg142098  Ezio said:
> Keep in mind that we should be able to access and use lone surrogates too, 
> therefore:
> s = '\ud800'  # should be valid
> len(s)  # should this raise an error? (or return 0.5 ;)?

I say:
For streams and data types in which lone surrogates are permitted, a lone 
surrogate should be treated as and counted as a character (codepoint).

For streams and data types in which lone surrogates are not permitted, the 
assigned should be invalid, and raise an error; len would then never see it, 
and has no quandary.

----------
nosy: +v+python

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue12729>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to