The character classes are used to define what a keyword looks like. For instance, in the C language, the acceptable characters making up a symbol are the upper and lower case letters, the digits (0-9) and the underscore. ABC_DEF is a perfectly valid symbol name. In some other language, maybe the underscore is not valid; in shell scripts, the dollar sign is used to introduce a symbol but can also terminate a symbol name, e.g. $HOST$PWD. The character class definitions are pseudo-regular expressions containing character classes using the [..] notation.