changeset 39773:51f74f0f7fce

(make_fixnum_or_float): New macro.
author Gerd Moellmann <gerd@gnu.org>
date Thu, 11 Oct 2001 15:37:13 +0000
parents 03dae03b95d9
children b34a792f4234
files src/lisp.h
diffstat 1 files changed, 6 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/src/lisp.h	Thu Oct 11 12:58:56 2001 +0000
+++ b/src/lisp.h	Thu Oct 11 15:37:13 2001 +0000
@@ -3086,3 +3086,9 @@
 #endif
 #define min(a, b)	((a) < (b) ? (a) : (b))
 #define max(a, b)	((a) > (b) ? (a) : (b))
+
+/* Return a fixnum or float, depending on whether VAL fits in a Lisp
+   fixnum.  */
+
+#define make_fixnum_or_float(val) \
+   (FIXNUM_OVERFLOW_P (val) ? make_float (val) : make_number (val))