7.20 General utilities <stdlib.h>
- 7.20.1 Numeric conversion functions
- 7.20.2 Pseudo-random sequence generation functions
- 7.20.3 Memory management functions
- 7.20.4 Communication with the environment
- 7.20.5 Searching and sorting utilities
- 7.20.6 Integer arithmetic functions
- 7.20.7 Multibyte/wide character conversion functions
- 7.20.8 Multibyte/wide string conversion functions
The header <stdlib.h> declares five types and several functions of general utility, and defines several macros.[1]
The types declared are size_t and wchar_t (both described in 7.17),
div_t
which is a structure type that is the type of the value returned by the div function,
ldiv_t
which is a structure type that is the type of the value returned by the ldiv function, and
lldiv_t
which is a structure type that is the type of the value returned by the lldiv function.
The macros defined are NULL (described in 7.17);
EXIT_FAILURE
and
EXIT_SUCCESS
which expand to integer constant expressions that can be used as the argument to the exit function to return unsuccessful or successful termination status, respectively, to the host environment;
RAND_MAX
which expands to an integer constant expression that is the maximum value returned by the rand function; and
MB_CUR_MAX
which expands to a positive integer expression with type size_t that is the maximum number of bytes in a multibyte character for the extended character set specified by the current locale (category LC_CTYPE), which is never greater than MB_LEN_MAX.
Footnotes