Mercurial > hg > octave-jordi > gnulib-hg
view doc/posix-functions/atof.texi @ 9821:18bab9955c43
Document various strtod bugs, with some fixes.
* doc/posix-functions/strtod.texi (strtod): Document bugs with
"-0x", "inf", "nan", and hex constants.
* doc/posix-functions/atof.texi (atof): Likewise.
* modules/stdlib (Makefile.am): Support strtod.
* m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Likewise.
* m4/strtod.m4 (gl_FUNC_STRTOD): Fit in stdlib framework, and
detect additional strtod bugs.
* lib/stdlib.in.h (rpl_strtod): Add declarations.
* lib/strtod.c (strtod): Return -0.0 on negative underflow. Use
bool where appropriate. Parse 'inf' and 'nan'.
* tests/test-strtod.c: New file.
* modules/strtod (Depends-on): Add stdbool, stdlib.
(configure.ac): Turn on module indicator.
* modules/strtod-tests: New module.
Signed-off-by: Eric Blake <ebb9@byu.net>
author | Eric Blake <ebb9@byu.net> |
---|---|
date | Sat, 29 Mar 2008 13:50:21 -0600 |
parents | 070329237839 |
children | c83dc7e8df57 |
line wrap: on
line source
@node atof @section @code{atof} @findex atof POSIX specification: @url{http://www.opengroup.org/susv3xsh/atof.html} Gnulib module: --- Portability problems fixed by Gnulib: @itemize @end itemize Portability problems not fixed by Gnulib: @itemize @item This function mis-parses strings with leading @samp{+} on some old platforms: Old versions of Linux. @item This function returns a positive value for negative underflow on some platforms: glibc 2.4, Mingw, Cygwin. @item This function fails to do a valid parse of @samp{-0x} on some platforms: glibc 2.4, Cygwin < 1.5.25-11. @item This function fails to parse Infinities and plain NaNs on some platforms: Solaris 8, Mingw, OpenBSD 4.0. @item This function fails to parse NaN() on some platforms: Solaris 8, Mingw, OpenBSD 4.0, Cygwin < 1.5.25-11. @item This function fails to parse NaN(n-char-sequence) on some platforms: Solaris 8, Mingw, OpenBSD 4.0. @item This function fails to parse C99 hexadecimal floating point on some platforms: Solaris 8, Mingw, OpenBSD 4.0. @item This function fails to correctly parse very long strings on some platforms: Mingw, Cygwin. @end itemize