home *** CD-ROM | disk | FTP | other *** search
/ Liren Large Software Subsidy 15 / 15.iso / s / s220 / 5.ddi / CTYPE.H < prev    next >
Encoding:
C/C++ Source or Header  |  1988-12-01  |  1.3 KB  |  37 lines

  1. /***    ctype.h
  2. /******************************************************************;
  3. ;*                                                                *;
  4. ;*          INTEL CORPORATION PROPRIETARY INFORMATION.            *;
  5. ;*   THIS LISTING IS SUPPLIED UNDER THE TERMS OF A LICENSE        *;
  6. ;*   AGREEMENT OR NON-DISCLOSURE AGREEMENT WITH INTEL CORPORATION *;
  7. ;*   AND MAY NOT BE COPIED NOR DISCLOSED EXCEPT IN ACCORDANCE     *;
  8. ;*   WITH THE TERMS OF THAT AGREEMENT.                            *;
  9. ;*                                                                *;
  10. ;******************************************************************/
  11.  
  12. #define L    0x01
  13. #define U    0x02
  14. #define D    0x04
  15. #define S    0x08
  16. #define P    0x10
  17. #define C    0x20
  18. #define X    0x40
  19. #define B    0x80
  20.  
  21. extern const char    _ctype_[];
  22.  
  23. #define    isalnum(c)    ((_ctype_)[c] & (U|L|D))
  24. #define    isalpha(c)    ((_ctype_)[c] & (U|L))
  25. #define    isascii(c)    ((unsigned)(c)<=0177)
  26. #define    iscntrl(c)    ((_ctype_)[c] & C)
  27. #define    isdigit(c)    ((_ctype_)[c] & D)
  28. #define    isgraph(c)    ((_ctype_)[c] & (P|U|L|D))
  29. #define    islower(c)    ((_ctype_)[c] & L)
  30. #define    isprint(c)    ((_ctype_)[c] & (P|U|L|D|B))
  31. #define    ispunct(c)    ((_ctype_)[c] & P)
  32. #define    isspace(c)    ((_ctype_)[c] & S)
  33. #define    isupper(c)    ((_ctype_)[c] & U)
  34. #define    isxdigit(c)    ((_ctype_)[c] & X)
  35. #define    _toupper(c)    ((c) & 0x5f)
  36. #define    _tolower(c)    ((c) | 0x20)
  37.