Functions | |
bool_t | lub_ctype_isdigit (char c) |
bool_t | lub_ctype_isspace (char c) |
char | lub_ctype_tolower (char c) |
char | lub_ctype_toupper (char c) |
The default manner in which to represent a string in C is to use a "char *". (NB. this is a signed type) The interfaces presented in <ctype.h> take signed integers. When a character greater than 128 is passed as a "char" to isspace() (e.g. the british pound sign "£") then a negative value is passed into the function/macro. A typical implementation (e.g. VxWorks) may use the passed argument as an offset into a lookup table, negative values in this case cause problems...
This utility provides an interface which avoids this ambiguity by passing "char" characters directly rather than converting to "int".
This component currently only contains those operations which are required by the current CLISH/LUB implementations. It can be extended on an as needed basis.
bool_t lub_ctype_isdigit | ( | char | c | ) |
This operation identifies whether a character is a decimal digit or not.
c | The character to check |
bool_t lub_ctype_isspace | ( | char | c | ) |
This operation identifies whether a character is a standard white space character. (space, tab, carriage-return, vertical tab, form-feed)
c | The character to check |
char lub_ctype_tolower | ( | char | c | ) |
This operation converts an uppercase letter to the corresponding lowercase letter.
c | The character to convert |
char lub_ctype_toupper | ( | char | c | ) |
This operation converts a lowercase letter to the corresponding uppercase letter.
c | The character to convert |