Neal Norwitz wrote: > > I feel I'm lacking some link here: why do you think we should do that? > > neal at janus ~/build/python/svn/clean-ish $ LC_ALL=de_DE ./python > >>> import locale > >>> locale.setlocale(locale.LC_ALL) > 'C' > >>> locale.setlocale(locale.LC_ALL, 'de_DE') > 'de_DE' > > I would have expected the first call to setlocale() to return de_DE. the locale is a program-specific setting (handled by the C runtime library), and is set to "C" by default. if you want to use a specific locale, you have to call setlocale to indicate that you really want a non-default locale. the "" argument is just a con- venience; it tells the C runtime library to set the locale based on OS-level language settings (e.g. LANG on Unix, control panel settings on Windows, etc). LANG in itself isn't the locale; it's just a way to tell a locale-aware program what the preferred locale is. </F>
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4