Source code of Windows XP (NT5)
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

33 lines
664 B

  1. package locale;
  2. =head1 NAME
  3. locale - Perl pragma to use and avoid POSIX locales for built-in operations
  4. =head1 SYNOPSIS
  5. @x = sort @y; # ASCII sorting order
  6. {
  7. use locale;
  8. @x = sort @y; # Locale-defined sorting order
  9. }
  10. @x = sort @y; # ASCII sorting order again
  11. =head1 DESCRIPTION
  12. This pragma tells the compiler to enable (or disable) the use of POSIX
  13. locales for built-in operations (LC_CTYPE for regular expressions, and
  14. LC_COLLATE for string comparison). Each "use locale" or "no locale"
  15. affects statements to the end of the enclosing BLOCK.
  16. =cut
  17. sub import {
  18. $^H |= 0x800;
  19. }
  20. sub unimport {
  21. $^H &= ~0x800;
  22. }
  23. 1;