The initial value of
to avoid programs that only require 8-bit strings needlessly creating larger string objects. If your application uses Unicode characters beyond the Latin-1 range (characters of type
) then you should consider which of the following two approaches to use:
extended-chars are constructed explicitly with the appropriate type. This is the conservative approach, allowing you to avoid allocation of 16-bit strings where these are not required. Note that you can use the specialised accessors such as
stcharfor strings of type simple-text-string.
(set-default-character-element-type 'simple-char)Bear in mind that this is a global setting which affects default string construction for the entire system. It could be called from a user interface, depending on whether the user needs to handle
Note: Do not attempt to bind or set directly the variable *default-character-element-type*.