28 #ifndef CTYPE_fb03932e_efff_11e9_b700_705a0f25cb51 29 #define CTYPE_fb03932e_efff_11e9_b700_705a0f25cb51 40 #define __CTYPE_VERSION (0x0001u) 42 #include "complier-cfg.h" 56 if ( ( ( (
unsigned)ch | 32U) -
'a' ) < 26 )
74 if ( ( (
unsigned)ch -
'0') < 10 )
109 if ( !( (
unsigned)ch & ~0x7f) )
127 if ( (ch < 0x20) || (ch == 0x7f) )
146 if ( ( (
unsigned)ch - 0x21) < 0x5e )
183 if ( ( (
unsigned)ch - 0x20) < 0x5f )
201 if ( ( ( (
unsigned)ch -
'\t') < 5 ) || ch ==
' ' )
219 if ( ( (
unsigned)(ch -
'0') < 10 ) || ( (
unsigned)(ch | 32) -
'a') < 6 )
237 if ( (
unsigned)(ch -
'a') < 26 )
255 if ( (
unsigned)(ch -
'A') < 26 )
291 return ( ch & 0x5f );
_STATIC_INLINE_ bool_et IsUpper(uint8_t ch)
Check a character is a upper case character or not. Ex. (A-Z)
Definition: ctype.h:253
_STATIC_INLINE_ uint8_t ToLower(uint8_t ch)
Convert a character to lower case character. Ex. (a-z) (A-Z) to (a-z)
Definition: ctype.h:270
bool_et
Boolean data type.
Definition: stddef.h:49
unsigned char uint8_t
8 bit unsigned integer. Unsigned integer type maximun and minimum limits
Definition: stdint.h:68
_STATIC_INLINE_ bool_et IsSpace(uint8_t ch)
Check a character is a space character or not. Ex. space.
Definition: ctype.h:199
_STATIC_INLINE_ bool_et IsHexDigit(uint8_t ch)
Check a character is a hexadecimal character or not. Ex. (0-9) (a-f) (A-F)
Definition: ctype.h:217
_STATIC_INLINE_ uint8_t ToUpper(uint8_t ch)
Convert a character to upper case character. Ex. (a-z) (A-Z) to (A-Z)
Definition: ctype.h:287
_STATIC_INLINE_ bool_et IsAscii(uint8_t ch)
Check a character is an ASCII character or not.
Definition: ctype.h:107
_STATIC_INLINE_ bool_et IsGraph(uint8_t ch)
Check a character is a graphical character or not. Ex. ! " # $ % & ' ( ) * + , - ....
Definition: ctype.h:144
Standard types and ctype function library.
_STATIC_INLINE_ bool_et IsPrintable(uint8_t ch)
Check a character is a printable character or not. Ex. All graphical character IsGraph include space.
Definition: ctype.h:181
#define _STATIC_INLINE_
Definition: complier-cfg.h:37
_STATIC_INLINE_ bool_et IsControl(uint8_t ch)
Check a character is a control character or not. Ex. ( - newline, \t - tab, \r - enter,...
Definition: ctype.h:125
_STATIC_INLINE_ bool_et IsLower(uint8_t ch)
Check a character is a lower case character or not. Ex. (a-z)
Definition: ctype.h:235
_STATIC_INLINE_ bool_et IsAlphaNumeric(uint8_t ch)
Check a character is an alphabetic and number character or not. Ex. (a-z) (A-Z) (0-9)
Definition: ctype.h:90
_STATIC_INLINE_ bool_et IsDigit(uint8_t ch)
Check a character is an number character or not. Ex. (0-9)
Definition: ctype.h:72
_STATIC_INLINE_ bool_et IsAlpha(uint8_t ch)
Check a character is an alphabet or not. Ex. (a-z) and (A-Z)
Definition: ctype.h:54
_STATIC_INLINE_ bool_et IsPunct(uint8_t ch)
Check a character is a punctuation character or not. Ex. ! " # $ % & ' ( ) * + , - ....
Definition: ctype.h:163