VariablePackage: exclToCDocOverviewCGDocRelNotesIndexPermutedIndex
Allegro CL version 6.2
Unrevised from 6.1

*locale*

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. *locale* is similar (in usage) to *package*. It can be bound while evaluating code for a different locale.

The current locale is used to determine the default external-format. In addition, the value of *locale* affects Allegro CL localization functions, which are listed below.

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)
                                       '(vector (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)
                                       '(vector (unsigned-byte 8))))
                      0))
#\pound_sign

See the localization functions locale-print-monetary, locale-format-monetary, locale-print-number, locale-format-number, locale-parse-number, locale-print-time, locale-format-time, locale-attribute. And see find-locale, locale-name, and locale-external-format.

General information on international character set support in Allegro CL is in iacl.htm. See particularly External formats and locales in that document.


Copyright (c) 1998-2002, Franz Inc. Oakland, CA., USA. All rights reserved.
Documentation for Allegro CL version 6.2. This page was not revised from the 6.1 page.
Created 2002.2.26.

ToCDocOverviewCGDocRelNotesIndexPermutedIndex
Allegro CL version 6.2
Unrevised from 6.1