def _print_locale():
categories = {}<EOL>def _init_categories(categories=categories):<EOL><INDENT>for k,v in list(globals().items()):<EOL><INDENT>if k[:<NUM_LIT:3>] == '<STR_LIT>':<EOL><INDENT>categories[k] = v<EOL><DEDENT><DEDENT><DEDENT>_init_categories()<EOL>del categories['<STR_LIT>']<EOL>print('<STR_LIT>')<EOL>print('<STR_LIT:->'*<NUM_LIT>)<EOL>lang, enc = getdefaultlocale()<EOL>print('<STR_LIT>', lang or '<STR_LIT>')<EOL>print('<STR_LIT>', enc or '<STR_LIT>')<EOL>print()<EOL>print('<STR_LIT>')<EOL>print('<STR_LIT:->'*<NUM_LIT>)<EOL>for name,category in list(categories.items()):<EOL><INDENT>print(name, '<STR_LIT>')<EOL>lang, enc = getlocale(category)<EOL>print('<STR_LIT>', lang or '<STR_LIT>')<EOL>print('<STR_LIT>', enc or '<STR_LIT>')<EOL>print()<EOL><DEDENT>print()<EOL>print('<STR_LIT>')<EOL>print('<STR_LIT:->'*<NUM_LIT>)<EOL>resetlocale()<EOL>for name,category in list(categories.items()):<EOL><INDENT>print(name, '<STR_LIT>')<EOL>lang, enc = getlocale(category)<EOL>print('<STR_LIT>', lang or '<STR_LIT>')<EOL>print('<STR_LIT>', enc or '<STR_LIT>')<EOL>print()<EOL><DEDENT>try:<EOL><INDENT>setlocale(LC_ALL, "<STR_LIT>")<EOL><DEDENT>except:<EOL><INDENT>print('<STR_LIT>')<EOL>print('<STR_LIT>')<EOL>print('<STR_LIT>')<EOL><DEDENT>else:<EOL><INDENT>print()<EOL>print('<STR_LIT>')<EOL>print('<STR_LIT:->'*<NUM_LIT>)<EOL>for name,category in list(categories.items()):<EOL><INDENT>print(name, '<STR_LIT>')<EOL>lang, enc = getlocale(category)<EOL>print('<STR_LIT>', lang or '<STR_LIT>')<EOL>print('<STR_LIT>', enc or '<STR_LIT>')<EOL>print()<EOL><DEDENT><DEDENT>
Test function.