long wcstol(const wchar_t *nptr, wchar_t **endptr, int base);
long long wcstoll(const wchar_t *nptr, wchar_t **endptr, int base);
unsigned long wcstoul(const wchar_t *nptr, wchar_t **endptr, int base);
unsigned long long wcstoul(const wchar_t *nptr, wchar_t **endptr, int base);
wcstoul- convert a wide character string to an unsigned long integer
wcstoull- convert a wide character string to an unsigned long long integer
wcstol returns, as a long integer, the value represented by the character string pointed to by nptr. wcstoul returns, as an unsigned long integer, the value represented by the character string pointed to by nptr. The string is scanned up to the first character inconsistent with the base. Leading ``white-space'' characters [as defined by iswspace] are ignored.
If the value of endptr is not a null pointer, a pointer to the wide character terminating the scan is returned in the location pointed to by endptr. If no integer can be formed, that location is set to nptr, and zero is returned.
If base is between 2 and 36, inclusive, it is used as the base for conversion. After an optional leading sign, leading zeros are ignored, and a leading ``0x'' or ``0X'' is ignored if base is 16 and a leading 0b or 0B is ignored if base is 2.
If base is zero, the string itself determines the base as follows: After an optional leading sign a leading zero indicates octal conversion, and a leading ``0x'' or ``0X'' hexadecimal conversion. Otherwise, decimal conversion is used.
wcstoll and wcstoull are similar functions that return a long long or unsigned long long, respectively.
For wcstoul, if the value represented by nptr would cause overflow, ULONG_MAX is returned, and errno is set to the value ERANGE.
If wcstol or wcstoul is given a base other than zero or 2 through 36, it returns zero and sets errno to EINVAL. Otherwise, wcstol and wcstoul return the represented value.