[I18n-sig] Perhaps the locale should matter?

Florian Weimer fw@deneb.cygnus.argh.org
05 May 2000 18:26:45 +0200

Guido van Rossum <guido@python.org> writes:

[Problem: implicit conversion from non-Unicode strings to Unicode, so
that existing Python code doesn't break when fed with both Unicode and
non-Unicode strings]

> Problem: I have no idea how to go from the locale setting (a
> two-charater language abbreviation) to a specific character encoding
> -- but that might conceivably a fixed table.

I like this idea a lot.  There was some discussion on the Linux-UTF-8
list <linux-utf8@nl.linux.org> on this topic (I'm Cc:ing them).
Current GNU libc development versions provide nl_langinfo() and
understand locale settings like "LANG=de_DE.UTF-8".  I don't know if
this convention is widely used, though.  If it isn't, there's probably
nothing else, so you could use it anyway. ;)