[issue22023] PyUnicode_FromFormat is broken on python 2
STINNER Victor
report at bugs.python.org
Tue Jul 22 00:18:19 CEST 2014
STINNER Victor added the comment:
Here is a patch fixing %S and %R formats and supporting %li and %zi. It fixes also %S, %R and %V for non-ASCII characters.
PyUnicode_FromFormat() of Python 2 doesn't support width, precision and padding. For example, "%100i" does crash. For %S, %R and %V, the function decodes byte strings from ISO-8859-1 in Python 2, whereas it decodes from UTF-8 in Python 3.
----------
keywords: +patch
Added file: http://bugs.python.org/file36017/unicode_fromformat.patch
_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue22023>
_______________________________________
More information about the Python-bugs-list
mailing list