summaryrefslogtreecommitdiff
path: root/src/stdlib/strtold.c
AgeCommit message (Collapse)AuthorLines
2012-04-10unify strtof/strtod/strtold wrappers and fix initial whitespace issueRich Felker-15/+0
2012-04-10new floating point parser/converterRich Felker-92/+11
this version is intended to be fully conformant to the ISO C, POSIX, and IEEE standards for conversion of decimal/hex floating point strings to float, double, and long double (ld64 or ld80 only at present) values. in particular, all results are intended to be rounded correctly according to the current rounding mode. further, this implementation aims to set the floating point underflow, overflow, and inexact flags to reflect the conversion performed. a moderate amount of testing has been performed (by nsz and myself) prior to integration of the code in musl, but it still may have bugs. so far, only strto(d|ld|f) use the new code. scanf integration will be done as a separate commit, and i will add implementations of the wide character functions later.
2011-04-03fix various bugs in strtold:Rich Felker-10/+13
0e10000000000000000000000000000000 was setting ERANGE exponent char e/p was considered part of the match even if not followed by a valid decimal value "1e +10" was parsed as "1e+10" hex digits were misinterpreted as 0..5 instead of 10..15
2011-03-25fix all implicit conversion between signed/unsigned pointersRich Felker-3/+3
sadly the C language does not specify any such implicit conversion, so this is not a matter of just fixing warnings (as gcc treats it) but actual errors. i would like to revisit a number of these changes and possibly revise the types used to reduce the number of casts required.
2011-02-12initial check-in, version 0.5.0v0.5.0Rich Felker-0/+93