CHERIoT RTOS
A compartmentalised RTOS for CHERIoT hardware
Loading...
Searching...
No Matches
ctype.h File Reference

ASCII-only definition of C standard C functions. More...

Go to the source code of this file.

Functions

static int isascii (int c)
 Returns true if c is a 7-bit ASCII character, false otherwise.
static int isdigit (int c)
 Returns true if c is an ASCII digit character, false otherwise.
static int islower (int c)
 Returns true if c is an ASCII lowercase character, false otherwise.
static int isprint (int c)
 Returns true if c is an ASCII printable character, false otherwise.
static int isspace (int c)
 Returns true if c is an ASCII whitespace character, false otherwise.
static int isupper (int c)
 Returns true if c is an ASCII uppercase character, false otherwise.
static int isalpha (int c)
 Returns true if c is an ASCII character that is part of the Latin alphabet, false otherwise.
static int isxdigit (int c)
 Returns true if c is an ASCII hexadecimal digit (0-f), false otherwise.
static int tolower (int c)
 Converts an uppercase ASCII character to a lowercase one, or returns the original value if c is not an uppercase character.
static int toupper (int c)
 Converts a lowercase ASCII character to a uppercase one, or returns the original value if c is not an lowercase character.

Detailed Description

ASCII-only definition of C standard C functions.

These functions are explicitly not locale aware. Apart from isascii, their return values are unspecified for non-ASCII character sets. Most embedded software does not need to be locale aware and talks to some back end that handles localisation. If you require support for Unicode or other non-ASCII character sets, do not use this file.

Definition in file ctype.h.

Function Documentation

◆ isalpha()

int isalpha ( int c)
inlinestatic

Returns true if c is an ASCII character that is part of the Latin alphabet, false otherwise.

Definition at line 82 of file ctype.h.

References islower(), and isupper().

◆ isascii()

int isascii ( int c)
inlinestatic

Returns true if c is a 7-bit ASCII character, false otherwise.

The value of c must be some ASCII-superset encoding, such as Unicode or an 8-bit code page.

Definition at line 22 of file ctype.h.

◆ isdigit()

int isdigit ( int c)
inlinestatic

Returns true if c is an ASCII digit character, false otherwise.

Definition at line 30 of file ctype.h.

Referenced by isxdigit().

◆ islower()

int islower ( int c)
inlinestatic

Returns true if c is an ASCII lowercase character, false otherwise.

Definition at line 38 of file ctype.h.

Referenced by isalpha(), and toupper().

◆ isprint()

int isprint ( int c)
inlinestatic

Returns true if c is an ASCII printable character, false otherwise.

Definition at line 46 of file ctype.h.

◆ isspace()

int isspace ( int c)
inlinestatic

Returns true if c is an ASCII whitespace character, false otherwise.

Definition at line 54 of file ctype.h.

◆ isupper()

int isupper ( int c)
inlinestatic

Returns true if c is an ASCII uppercase character, false otherwise.

Definition at line 73 of file ctype.h.

Referenced by isalpha(), and tolower().

◆ isxdigit()

int isxdigit ( int c)
inlinestatic

Returns true if c is an ASCII hexadecimal digit (0-f), false otherwise.

Definition at line 90 of file ctype.h.

References isdigit().

◆ tolower()

int tolower ( int c)
inlinestatic

Converts an uppercase ASCII character to a lowercase one, or returns the original value if c is not an uppercase character.

Definition at line 100 of file ctype.h.

References isupper().

◆ toupper()

int toupper ( int c)
inlinestatic

Converts a lowercase ASCII character to a uppercase one, or returns the original value if c is not an lowercase character.

Definition at line 109 of file ctype.h.

References islower().