Commit | Line | Data |
---|---|---|
2ba4d529 | 1 | /* |
992de934 | 2 | * @(#)ectype.h 1.2 (Berkeley) %G% |
2ba4d529 GM |
3 | */ |
4 | ||
5 | #define INCLUDED_ECTYPE | |
6 | ||
7 | #define E_UPPER 0x01 | |
8 | #define E_LOWER 0x02 | |
9 | #define E_DIGIT 0x04 | |
10 | #define E_SPACE 0x08 | |
11 | #define E_PUNCT 0x10 | |
12 | #define E_PRINT 0x20 | |
13 | ||
14 | #define Eisalpha(c) (ectype[(c)&0xff]&(E_UPPER|E_LOWER)) | |
15 | #define Eisupper(c) (ectype[(c)&0xff]&E_UPPER) | |
16 | #define Eislower(c) (ectype[(c)&0xff]&E_LOWER) | |
17 | #define Eisdigit(c) (ectype[(c)&0xff]&E_DIGIT) | |
18 | #define Eisalnum(c) (ectype[(c)&0xff]&(E_UPPER|E_LOWER|E_DIGIT)) | |
19 | #define Eisspace(c) (ectype[(c)&0xff]&E_SPACE) /* blank or null */ | |
20 | #define Eispunct(c) (ectype[(c)&0xff]&E_PUNCT) | |
21 | #define Eisprint(c) (ectype[(c)&0xff]&E_PRINT) |