[issue20049] string.lowercase and string.uppercase can contain garbage

R. David Murray report at bugs.python.org
Sun Dec 22 00:21:36 CET 2013


R. David Murray added the comment:

In python2, string.lowercase and string.uppercase are locale dependent.  This isn't really all that useful in practice, which is why it was dropped in Python3.  The proposed fix might be correct, *if* utf-8 is checked for (see, eg, Issue 6525), but...do you have any idea why this is a problem on illumos with _XOPEN_SOURCE=600 but not on any other platform (as far as we know)?  It seems like it would be a bug in the platform's islower and isupper functions, which are supposed to operate on integers that fit in an unsigned char, and be locale aware, according to the standards.

----------
nosy: +r.david.murray

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


More information about the Python-bugs-list mailing list