newlib: strtold: use __builtin_nanl to avoid libm dependency
Commit 6c212a8b78
("Fix strtod ("nan") and strtold ("nan") returns wrong negative NaN")
introduced an unconditional dependency to nanl and, in turn, to libm.
Rather than including nanl in libc as well, just call __builtin_nanl
from here. Requires GCC 3.3 or later.
Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
This commit is contained in:
@@ -89,7 +89,7 @@ ULtox(__UShort *L, __ULong *bits, Long exp, int k)
|
|||||||
break;
|
break;
|
||||||
|
|
||||||
case STRTOG_NaN:
|
case STRTOG_NaN:
|
||||||
*((long double*)L) = nanl ("");
|
*((long double*)L) = __builtin_nanl ("");
|
||||||
}
|
}
|
||||||
if (k & STRTOG_Neg)
|
if (k & STRTOG_Neg)
|
||||||
L[_0] |= 0x8000;
|
L[_0] |= 0x8000;
|
||||||
|
Reference in New Issue
Block a user