New submission from zy <[email protected]>:
let s='\xff\n'
The expected result of s.decode('gb2312', 'ignore') is u"\n", while in 2.6.6 it
is u"".
s can be replaced with chr(m) + chr(n) , where m is in range of 128~255, and
n in 0~127.
In the above cases, try decoding from chr(n) will never interfere with later
parts in the string if there is any, since chr(n) do not start a multibyte
sequence.
----------
components: Unicode
messages: 135268
nosy: cdqzzy
priority: normal
severity: normal
status: open
title: Wrong behavior for '\xff\n'.decode('gb2312', 'ignore')
type: behavior
versions: Python 2.6
_______________________________________
Python tracker <[email protected]>
<http://bugs.python.org/issue12016>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe:
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com