Stefan Krah <stefan-use...@bytereef.org> added the comment: This fails in _localemodule.c: str2uni(). mbstowcs(NULL, s, 0) is LC_CTYPE sensitive, but LC_CTYPE is UTF-8 in my terminal.
If I set LC_CTYPE and LC_NUMERIC together, things work. This raises the question: If LC_CTYPE and LC_NUMERIC differ (and since they are separate entities I assume they may differ), what is the correct way to convert the separator and the decimal point? a) call setlocale(LC_CTYPE, setlocale(LC_NUMERIC, NULL)) before mbstowcs. This is not really an option. b) use some kind of _mbstowcs_l (http://msdn.microsoft.com/en-us/library/k1f9b8cy(VS.80).aspx), which takes a locale parameter. But I don't find such a thing on Linux. ---------- _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue7442> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com