I would like to remove the support for using libc wctype functions (e.g. towupper(), towlower(), etc.) from the code base.
The reason is that compiling Python using this switch not only breaks the test suite, it also causes the functions .lower() and .upper() to become locale aware and creates wrong results as a result (which are hard to track down if you don't know whether Python was compiled with the wctype switch or not).
The argument for having this switch at the time was to reduce the interpreter size. This was true for Python 1.6 since the Unicode type database was conditionally removed. Starting with Python 2.0 a different approach was taken which resulted in having to keep the type database in one piece - even with the switch enabled.
As a result, performance became the only argument. However, because the libc functions are locale aware, the added overhead causes the libc functions not to perform better than the builtin Python versions.
In the end, we loose complexity and reduce the Python configuration space by one dimension.
Here's the bug that revealed the problem:
Question is: Should this be done in 2.4.1 or will it have to wait until 2.5 ?
We might want to remove the support for 2.4.1 and simply ignore the compile time switch (or print a warning).