IS_INF: Undid last change.
authorDirk Herrmann <dirk@dirk-herrmanns-seiten.de>
Wed, 10 May 2000 09:25:11 +0000 (09:25 +0000)
committerDirk Herrmann <dirk@dirk-herrmanns-seiten.de>
Wed, 10 May 2000 09:25:11 +0000 (09:25 +0000)
libguile/ChangeLog
libguile/numbers.c

index 81c4ad3..602f1fc 100644 (file)
@@ -1,3 +1,11 @@
+2000-05-10  Dirk Herrmann  <D.Herrmann@tu-bs.de>
+
+       * numbers.c:  No need to include unif.h.
+
+       (IS_INF):  Returned to old test for now:  x == x + 1 will not work
+       for large numbers due to rounding errors.
+       Thanks to Kalle Olavi Niemitalo.
+
 2000-05-09  Dirk Herrmann  <D.Herrmann@tu-bs.de>
 
        * numbers.c (scm_divbigdig):  Removed outdated comment.
index 5fa35f8..bd40ae6 100644 (file)
@@ -47,7 +47,6 @@
 #include <stdio.h>
 #include <math.h>
 #include "libguile/_scm.h"
-#include "libguile/unif.h"
 #include "libguile/feature.h"
 #include "libguile/ports.h"
 #include "libguile/root.h"
@@ -74,7 +73,7 @@ static SCM scm_divbigint (SCM x, long z, int sgn, int mode);
 /* IS_INF tests its floating point number for infiniteness
  */
 #ifndef IS_INF
-#define IS_INF(x) ((x) == (x) + 1)
+#define IS_INF(x) ((x) == (x) / 2)
 #endif
 
 /* Return true if X is not infinite and is not a NaN