PEP 538: clarify setlocale behaviour in POSIX locale

This commit is contained in:
Nick Coghlan 2017-01-07 22:14:20 +10:00
parent 858909a1d2
commit c2aa424e28
1 changed files with 3 additions and 0 deletions

View File

@ -330,6 +330,9 @@ exactly the ``C`` locale with ``strcmp``::
ctype_loc != NULL && strcmp(ctype_loc, "C") == 0 # true only in the C locale
This call also returns ``"C"`` when either no particular locale is set, or the
nominal locale is set to an alias for the ``C`` locale (such as ``POSIX``).
Given this information, CPython can then attempt to coerce the locale to one
that uses UTF-8 rather than ASCII as the default encoding.