Ben Finney <[email protected]>: > Steven D'Aprano <[email protected]> writes: > >> '\udd00' should be a SyntaxError. > > I find your argument convincing, that attempting to construct a > Unicode string of a lone surrogate should be an error.
Then we're back to square one:
>>> b'\x80'.decode('utf-8', errors='surrogateescape')
'\udc80'
Marko
--
https://mail.python.org/mailman/listinfo/python-list
