Everything

strtold [V1.07 or later]


Conversion of character string to floating-point number (long double type) and storing pointer to last character string

[Classification]

Standard library

[Syntax]

#include <stdlib.h>

long double __far strtold(const char __near * restrict nptr, char __near * __near * restrict endptr); (C99)

long double __far _COM_strtold_ff(const char __far * restrict nptr, char __far * __far * restrict endptr); (C99)

[Return value]

If the partial character string has been converted, the converted value is returned. If the character string could not be converted, 0 is returned.

If an overflow occurs, this function returns ±∞ and sets macro ERANGE to global variable errno.

If an underflow occurs, this function returns 0 and sets macro ERANGE to global variable errno.

[Description]

This function skips 0 or more columns of white-space characters (character which makes the isspace function true) from the start of the string indicated by nptr, and converts the string from the next character into a long double-type representation. When endptr is not a null pointer, the pointer to the remaining strings that were not converted is set in endptr.

[Restrictions]

Hexadecimal floating-point numbers are not supported in a recognizable format of a string that is subject to the conversion method specified in the C99 standard.