| CTypeTable | Variable (Macro)

system.h

const unsigned char *CTypeTable;

A pointer to a table describing the types of the AMS characters.

This table contains 256 elements, one for each character.
There are nine different values in this table:
0x00 (0b00000000): characters 0x00-0x0A and 0x0C-0x0D. These characters are not supposed to occur in any string returned by the system, they are not part of the char menu either.
0x40 (0b01000000): characters 0x0B, 0x0E, 0x0F, 0x10-0x2F (system characters + some of the operators), 0x3A-0x3F (colon, semicolon...), 0x40 (at sign), 0x5B-0x5E (brackets...), 0x60, 0x7B-0x7F (braces...), 0x95-0xB4 (maths symbols...), 0xB6-0xBF (maths symbols...), 0xD7, 0xF7. These symbols are used by the pretty print, or available in the char menu (some are incorrect in expressions)...
0x48 (0b01001000): character 0x5F (question mark).
0x4C (0b01001100): characters 0x30-0x39, i.e. numerals.
0x58 (0b01011000): characters 0xDF and 0xFF (�and ).
0x59 (0b01011001): characters 0x61-0x7B, 0xE0-0xEF, 0xF0-0xF6, 0xF8-0xFE. These characters are lowercase letters, accentuated or not.
0x5A (0b01011010): characters 0x41-0x5B, 0xC0-0xCF, 0xD0-0xD6, 0xD8-0xDE. These characters are uppercase letters, accentuated or not.
0x60 (0b01100000): character 0x8C (pi).
0x78 (0b01111000): characters 0x80-0x8B, 0x8D-0x8F, 0x90-0x94, 0xB5 (). These characters are all greek letters (no meaning for the system), without pi (0x60).
To sum up:
bit 0 set means: 'character is a lowercase letter' (type 0x59).
bit 1 set means: 'character is a uppercase letter' (type 0x5A).
(bits 0 and 1 are mutually exclusive).
bit 2 set means: 'character is a numeral' (type 0x4C).
bit 3 set means: 'character is valid in a symbol name' (types 0x00, 0x40 and 0x60 are invalid in symbol names).
bit 4 set means: 'character is valid as starting character for a symbol name' (types 0x48 and 0x4C are invalid as first character in symbol names).
bit 5 set means: 'character is a greek letter' (types 0x60 and 0x78).
bit 6 set means: 'character is printable' (all types except 0x00).
bit 7 is currently unused.
Credits go to Zeljko Juric for the trick used to retrieve the address of that table. This wrapper implements ROM_CALL 442 on any AMS version.

Used by: EQU_getNameInfo, GetStatValue, gr_del_locals, GT_Trace, init_unit_system, next_token, nonblank, ParseSymName, push_format, push_parse_prgm_or_func_text, push_user_func, push_var, setup_unit_system, is_independent_of_de_seq_vars, push_parse_text, handleVarLinkKey, MO_digestOptions, GD_Text, MenuKey, ST_folder, sprintf, cmpstri, stricmp, TE_handleEvent, CheckSysFunc, FolderCurTemp, StrToTokN, ValidateSymName, VarRecall, VarStore, ROM Call 0x421, ROM Call 0x4D4