[issue13706] non-ascii fill characters no longer work in numeric formatting

Martin v. Löwis report at bugs.python.org
Wed Jan 4 00:07:35 CET 2012


Martin v. Löwis <martin at v.loewis.de> added the comment:

Removing the if condition would be incorrect. The maximum char is computed at the beginning of the formatting. If, during formatting, need for a padding character is determined, the padding character must not be larger than the maximum char of the target string - which is 127 unless 'c' formatting is used.

One solution would be to determine whether the padding character is used in advance. Another solution would be to widen the string when the need for non-ASCII padding is detected.

I have no intention of fixing this issue myself; I don't mind if non-ASCII padding characters are not supported in 3.3.

----------

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue13706>
_______________________________________


More information about the Python-bugs-list mailing list