40 while (isspace(**str)) ++*
str;
102 val = strtoimax(str, &end, 0);
110 if (str == end || *end !=
'\0' || (
errno == ERANGE &&
111 (val == INTMAX_MIN || val == INTMAX_MAX))) {
129 val = strtoumax(str, &end, 0);
137 if ((str == end || *end !=
'\0' || (
errno == ERANGE && val == UINTMAX_MAX))) {
int ast_str_to_long(const char *str, long *res)
Convert the given string to a signed long.
int ast_str_to_int(const char *str, int *res)
Convert the given string to a signed integer.
int ast_str_to_ulong(const char *str, unsigned long *res)
Convert the given string to an unsigned long.
static int str_is_negative(const char **str)
Conversion utility functions.
int ast_str_to_umax(const char *str, uintmax_t *res)
Convert the given string to an unsigned max size integer.
int ast_str_to_uint(const char *str, unsigned int *res)
Convert the given string to an unsigned integer.
int ast_str_to_imax(const char *str, intmax_t *res)
Convert the given string to a signed max size integer.