Embedded Artistry Framework
Embedded Systems C++ Framework
Functions
atoll.c File Reference
#include <ctype.h>
#include <stdbool.h>
#include <stdlib.h>
Include dependency graph for atoll.c:

Functions

long long atoll (const char *str)
 Interprets a Long Long value in a byte string pointed to by str. More...
 

Function Documentation

◆ atoll()

long long atoll ( const char *  str)

Interprets a Long Long value in a byte string pointed to by str.

Interprets a Long Long value in a byte string pointed to by str. Discards any whitespace characters until the first non-whitespace character is found, then takes as many characters as possible to form a valid long number representation and converts them to an long long value. The valid Long long value consists of the following parts: a) (optional) plus or minus sign b) numeric digits

Parameters
strpointer to the null-terminated byte string to be interpreted
Returns
long value corresponding to the contents of str on success. If the converted value falls out of range of corresponding return type, the return value is undefined. If no conversion can be performed, ​0​ is returned.

References isdigit(), and isspace().

Referenced by atoll_test().

Here is the caller graph for this function: