+2011-05-22 Paul Eggert <eggert@cs.ucla.edu>
+
+ * lisp.h (FIXNUM_OVERFLOW_P): Work even if arg is a NaN.
+
2011-05-21 Paul Eggert <eggert@cs.ucla.edu>
* data.c: Avoid integer truncation in expressions involving floats.
/* Value is non-zero if I doesn't fit into a Lisp fixnum. It is
written this way so that it also works if I is of unsigned
- type. */
+ type or if I is a NaN. */
#define FIXNUM_OVERFLOW_P(i) \
- ((i) > MOST_POSITIVE_FIXNUM \
- || ((i) < 0 && (i) < MOST_NEGATIVE_FIXNUM))
+ (! ((0 <= (i) || MOST_NEGATIVE_FIXNUM <= (i)) && (i) <= MOST_POSITIVE_FIXNUM))
/* Extract a value or address from a Lisp_Object. */