XenevaOS
Loading...
Searching...
No Matches
XenevaOS
Libs
XEClib
includes
ctype.h
Go to the documentation of this file.
1
30
#ifndef __CTYPE_H__
31
#define __CTYPE_H__
32
33
#include <
_xeneva.h
>
34
35
#ifdef __cplusplus
36
extern
"C"
{
37
#endif
38
39
XE_LIB
int
isspace
(
int
c);
40
XE_LIB
int
isascii
(
int
c);
41
XE_LIB
int
isupper
(
int
c);
42
XE_LIB
int
islower
(
int
c);
43
XE_LIB
int
isalpha
(
int
c);
44
XE_LIB
int
isdigit
(
int
c);
45
XE_LIB
int
isxdigit
(
int
c);
46
XE_LIB
int
isprint
(
int
c);
47
XE_LIB
int
toupper
(
int
c);
48
XE_LIB
int
tolower
(
int
c);
49
50
#define toascii(c) ((unsigned)(c) & 0x7F)
51
52
#if 0
53
54
extern
char
_ctype
[257];
55
56
/* Constants */
57
58
#define _LEADBYTE 0x8000
// Multibyte leadbyte
59
#define _ALPHA (0x0100 | _UPPER | _LOWER)
// Alphabetic character
60
61
#define CT_UP 0x01
/* upper case */
62
#define CT_LOW 0x02
/* lower case */
63
#define CT_DIG 0x04
/* digit */
64
#define CT_CTL 0x08
/* control */
65
#define CT_PUN 0x10
/* punctuation */
66
#define CT_WHT 0x20
/* white space (space/cr/lf/tab) */
67
#define CT_HEX 0x40
/* hex digit */
68
#define CT_SP 0x80
/* hard space (0x20) */
69
70
/* Basic macros */
71
72
#define isalnum(c) ((_ctype + 1)[(unsigned)(c)] & (CT_UP | CT_LOW | CT_DIG))
73
#define isalpha(c) ((_ctype + 1)[(unsigned)(c)] & (CT_UP | CT_LOW))
74
#define iscntrl(c) ((_ctype + 1)[(unsigned)(c)] & (CT_CTL))
75
#define isdigit(c) ((_ctype + 1)[(unsigned)(c)] & (CT_DIG))
76
#define isgraph(c) ((_ctype + 1)[(unsigned)(c)] & (CT_PUN | CT_UP | CT_LOW | CT_DIG))
77
#define islower(c) ((_ctype + 1)[(unsigned)(c)] & (CT_LOW))
78
#define isprint(c) ((_ctype + 1)[(unsigned)(c)] & (CT_PUN | CT_UP | CT_LOW | CT_DIG | CT_SP))
79
#define ispunct(c) ((_ctype + 1)[(unsigned)(c)] & (CT_PUN))
80
#define isspace(c) ((_ctype + 1)[(unsigned)(c)] & (CT_WHT))
81
#define isupper(c) ((_ctype + 1)[(unsigned)(c)] & (CT_UP))
82
#define isxdigit(c) ((_ctype + 1)[(unsigned)(c)] & (CT_DIG | CT_HEX))
83
84
#endif
85
86
#ifdef __cplusplus
87
}
88
#endif
89
90
#endif
tolower
#define tolower(c)
Definition
ctype.h:63
isascii
#define isascii(c)
Definition
ctype.h:37
toupper
#define toupper(c)
Definition
ctype.h:64
_ctype
const unsigned char _ctype[]
_xeneva.h
XE_LIB
#define XE_LIB
Definition
_xeneva.h:55
isspace
#define isspace(c)
Definition
acclib.h:177
islower
#define islower(c)
Definition
acclib.h:180
isalpha
#define isalpha(c)
Definition
acclib.h:182
isdigit
#define isdigit(c)
Definition
acclib.h:176
isprint
#define isprint(c)
Definition
acclib.h:181
isxdigit
#define isxdigit(c)
Definition
acclib.h:178
isupper
#define isupper(c)
Definition
acclib.h:179
Generated by
1.9.8