ASPN ActiveState Programmer Network
  ActiveState
/ Home / Perl / PHP / Python / Tcl / XSLT /
/ Safari / My ASPN /
Cookbooks | Documentation | Mailing Lists | Modules | News Feeds | Products | User Groups | Web Services
SEARCH
advanced | search help

Reference
ActivePerl 5.10
Pragmas
attributes
attrs
autouse
base
bigint
bignum
bigrat
blib
bytes
charnames
constant
diagnostics
encoding
encoding warnings
feature
fields
filetest
if
integer
less
lib
locale
mro
open
ops
overload
re
sigtrap
sort
strict
subs
threads
threads shared
utf8
vars
version
vmsish
warnings
warnings register

MyASPN >> Reference >> ActivePerl 5.10 >> Pragmas
ActivePerl 5.10 documentation

NAME

locale - Perl pragma to use and avoid POSIX locales for built-in operations


SYNOPSIS

    @x = sort @y;       # ASCII sorting order
    {
        use locale;
        @x = sort @y;   # Locale-defined sorting order
    }
    @x = sort @y;       # ASCII sorting order again


DESCRIPTION

This pragma tells the compiler to enable (or disable) the use of POSIX locales for built-in operations (LC_CTYPE for regular expressions, and LC_COLLATE for string comparison). Each "use locale" or "no locale" affects statements to the end of the enclosing BLOCK.

See the perllocale manpage for more detailed information on how Perl supports locales.


Privacy Policy | Email Opt-out | Feedback | Syndication
© ActiveState 2004 All rights reserved