Contents    Page-10    Prev    Next    Page+10    Index   

Character Classes

At the lowest level of grammar, there is a need to classify characters into classes. This can be done by lookup in an array indexed by the character code. Typical classes include:

Special characters may be mapped to consecutive integers to allow the resulting index to be used in case statements.

Char ASCII Class
...
0 608 0
1 618 0
...
A 1018 1
B 1028 1
...