Dear all,
This patch introduces two new functions:
-- Built-in Function: L = locale ()
-- Built-in Function: BOOL = locale (L)
Get the user's locale or check if the specified one is installed
on the system.
On GNU/Linux you can check the installed locales by issuing
`locale -a' at the shell.
locale ()
=> "en_US.UTF-8"
locale ("pt_BR")
=> true
locale ("fr_FR")
=> false
*See also:* setlocale.
and
-- Built-in Function: OLD = setlocale (NEW)
Set the locale and return the previous.
setlocale (locale ())
=> "C"
setlocale (locale ())
=> "en_US.UTF-8"
*See also:* locale.
I don't know if corefcn is the better place for them, any suggestions? Any comments you want to add about the code? What could be done better?
The patch also fixes an old test failure with sscanf() and locale.
Best,
Júlio.