*locale*

Variable

Package: excl

The value of this variable must be a locale object. Its initial value is the default locale based on the Lisp process' external locale setting (see The initial locale when Allegro CL starts up in iacl.htm). The locale object which is the value of excl:*locale* is referred to as the current locale. excl:*locale* is similar (in usage) to *package*. It can be bound while evaluating code for a different locale.

In Allegro CL 6.0, the current locale is only used to determine the default external-format. Nothing else within Allegro CL 6.0 uses or depends on *locale*, although future releases may expand on how *locale* is used.

Examples:

The Polish locale, "pl", uses the Latin-2 character set; and the US English locale, "en_US", uses the Latin-1 character set. The octet value #xa3 represents a different external-format character in each character set. Rebinding excl:*locale* as shown below alters the default external-format conversion behavior.

user(22): (let ((excl:*locale* (find-locale "pl")))
              (schar (octets-to-string (coerce
                                       '(#xa3)
                                       '(array (unsigned-byte 8))))
              0))
#\latin_capital_letter_l_with_stroke

user(23): (let ((excl:*locale* (find-locale "en_US")))
              (schar (octets-to-string (coerce
                                       '(#xa3)
                                       '(array (unsigned-byte 8))))
                      0))
#\pound_sign

General information on international character set support in Allegro CL is in iacl.htm. See particularly Locales in that document.

The documentation is described in introduction.htm and the index is in index.htm.

Copyright (c) 1998-2000, Franz Inc. Berkeley, CA., USA. All rights reserved.

Created 2000.10.5.