PennMUSH Community

root/1.8.3/trunk/hdrs/case.h

Revision 919, 417 bytes (checked in by shawnw, 1 year ago)

1.8.3p3

Line 
1 #ifndef CASE_H
2 #define CASE_H
3 #include <ctype.h>
4 #include "config.h"
5
6 #ifdef HAVE_SAFE_TOUPPER
7 #define DOWNCASE(x)     tolower((unsigned char)x)
8 #define UPCASE(x)       toupper((unsigned char)x)
9 #else
10 #define DOWNCASE(x) (isupper((unsigned char)x) ? tolower((unsigned char)x) : (x))
11 #define UPCASE(x)   (islower((unsigned char)x) ? toupper((unsigned char)x) : (x))
12 #endif
13 #endif                          /* CASE_H */
Note: See TracBrowser for help on using the browser.