test-strtod: fix typos: s/abs/fabs/
authorJim Meyering <meyering@redhat.com>
Mon, 14 Apr 2008 08:20:22 +0000 (10:20 +0200)
committerJim Meyering <meyering@redhat.com>
Mon, 14 Apr 2008 08:20:22 +0000 (10:20 +0200)
* tests/test-strtod.c (main): Use fabs, not narrowing-to-int "abs".

ChangeLog
tests/test-strtod.c

index 5b205be..6d6fd8d 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2008-04-14  Jim Meyering  <meyering@redhat.com>
+
+       test-strtod: fix typos: s/abs/fabs/
+       * tests/test-strtod.c (main): Use fabs, not narrowing-to-int "abs".
+
 2008-04-13  Bruno Haible  <bruno@clisp.org>
 
        Fix conflict between modules 'canonicalize' and 'canonicalize-lgpl'.
index 6c63e13..12d3606 100644 (file)
@@ -163,7 +163,7 @@ main ()
     /* FIXME - gnulib's version is rather inaccurate.  It would be
        nice to guarantee an exact result, but for now, we settle for a
        1-ulp error.  */
-    ASSERT (abs (result - 0.5) < DBL_EPSILON);
+    ASSERT (fabs (result - 0.5) < DBL_EPSILON);
     ASSERT (ptr == input + 2);
     ASSERT (errno == 0);
   }
@@ -246,7 +246,7 @@ main ()
     /* FIXME - gnulib's version is rather inaccurate.  It would be
        nice to guarantee an exact result, but for now, we settle for a
        1-ulp error.  */
-    ASSERT (abs (result - 0.5) < DBL_EPSILON);
+    ASSERT (fabs (result - 0.5) < DBL_EPSILON);
     ASSERT (ptr == input + 4);
     ASSERT (errno == 0);
   }