diff options
author | Thomas Schwinge <thomas@codesourcery.com> | 2013-04-05 20:28:47 +0200 |
---|---|---|
committer | Thomas Schwinge <thomas@codesourcery.com> | 2013-04-05 22:41:20 +0200 |
commit | ee091edf1a16312fff0cc3c6ae0116aded7f1dbf (patch) | |
tree | 644d3aebe2270770af04f42a32cd70715967cf1b /stdlib | |
parent | a8b792d6bb54fda2ff66f8b0c725397d402f367e (diff) | |
download | glibc-ee091edf1a16312fff0cc3c6ae0116aded7f1dbf.zip glibc-ee091edf1a16312fff0cc3c6ae0116aded7f1dbf.tar.gz glibc-ee091edf1a16312fff0cc3c6ae0116aded7f1dbf.tar.bz2 |
More tests for external charater sequences representing NaNs.
Diffstat (limited to 'stdlib')
-rw-r--r-- | stdlib/Makefile | 1 | ||||
-rw-r--r-- | stdlib/tst-strtod6.c | 15 |
2 files changed, 16 insertions, 0 deletions
diff --git a/stdlib/Makefile b/stdlib/Makefile index 6f98c71..27765d1 100644 --- a/stdlib/Makefile +++ b/stdlib/Makefile @@ -157,6 +157,7 @@ $(objpfx)bug-getcontext: $(link-libm) $(objpfx)tst-strtod-round: $(link-libm) $(objpfx)tst-tininess: $(link-libm) $(objpfx)tst-strtod-underflow: $(link-libm) +$(objpfx)tst-strtod6: $(link-libm) tst-tls-atexit-lib.so-no-z-defs = yes diff --git a/stdlib/tst-strtod6.c b/stdlib/tst-strtod6.c index fdb104f..1d87266 100644 --- a/stdlib/tst-strtod6.c +++ b/stdlib/tst-strtod6.c @@ -16,6 +16,11 @@ do_test (void) puts ("strtod did not return NAN"); result = 1; } + if (issignaling (d)) + { + puts ("strtod returned a sNAN"); + result = 1; + } if (strcmp (endp, "something") != 0) { puts ("strtod set incorrect end pointer"); @@ -28,6 +33,11 @@ do_test (void) puts ("strtof did not return NAN"); result = 1; } + if (issignaling (f)) + { + puts ("strtof returned a sNAN"); + result = 1; + } if (strcmp (endp, "something") != 0) { puts ("strtof set incorrect end pointer"); @@ -40,6 +50,11 @@ do_test (void) puts ("strtold did not return NAN"); result = 1; } + if (issignaling (ld)) + { + puts ("strtold returned a sNAN"); + result = 1; + } if (strcmp (endp, "something") != 0) { puts ("strtold set incorrect end pointer"); |