[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

char-equal of control characters

We're encountering continuing difficulties caused by the fact that
CHAR-EQUAL (and the related character and string functions) ignores
differences in the bits attribute, so that (CHAR-EQUAL #\A #\Control-A)
is true.  Does anyone remember the motivation for specifying CHAR-EQUAL
this way?  It's not set forth in the Common Lisp manual.  I went through
all my old draft manuals, back to to Colander edition of 29 July 1982,
but found no illumination.

Since graphic-char-p, alpha-char-p, upper-case-p, and digit-char-p
are influenced by the bits attribute of a character, it appears that
two characters with different bits attributes are considered to be
essentially different, in the same way that pea and pi are essentially
different (see the example under CHAR-EQUAL in the manual).

I'm not proposing to change anything at this time, but I'd like to
understand the motivation.  Can the other designers of Common Lisp
comment on this?  Do any of the other implementors of Common Lisp
have relevant experience to offer?