Mercurial > emacs
changeset 27727:9400865ec7cf
Remove `LISP_FLOAT_TYPE' and `standalone'.
author | Gerd Moellmann <gerd@gnu.org> |
---|---|
date | Thu, 17 Feb 2000 09:45:46 +0000 |
parents | 9627810a3fed |
children | 01121d3b9952 |
files | src/Makefile.in src/alloc.c src/bytecode.c src/config.in src/data.c src/dispnew.c src/ecrt0.c src/editfns.c src/emacs.c src/floatfns.c src/fns.c src/lisp.h src/lread.c src/print.c |
diffstat | 14 files changed, 9 insertions(+), 218 deletions(-) [+] |
line wrap: on
line diff
--- a/src/Makefile.in Thu Feb 17 09:20:23 2000 +0000 +++ b/src/Makefile.in Thu Feb 17 09:45:46 2000 +0000 @@ -127,11 +127,7 @@ #endif #ifndef LIB_MATH -# ifdef LISP_FLOAT_TYPE # define LIB_MATH -lm -# else /* ! defined (LISP_FLOAT_TYPE) */ -# define LIB_MATH -# endif /* ! defined (LISP_FLOAT_TYPE) */ #endif /* LIB_MATH */ /* Some s/SYSTEM.h files define this to request special switches in ld. */ @@ -628,11 +624,7 @@ #define FACE_SUPPORT #endif -#ifdef LISP_FLOAT_TYPE #define FLOAT_SUPPORT ${lispsource}float-sup.elc -#else -#define FLOAT_SUPPORT -#endif #ifdef HAVE_MOUSE #define MOUSE_SUPPORT ${lispsource}mouse.elc \
--- a/src/alloc.c Thu Feb 17 09:20:23 2000 +0000 +++ b/src/alloc.c Thu Feb 17 09:45:46 2000 +0000 @@ -151,9 +151,7 @@ int total_conses, total_markers, total_symbols, total_vector_size; int total_free_conses, total_free_markers, total_free_symbols; -#ifdef LISP_FLOAT_TYPE int total_free_floats, total_floats; -#endif /* LISP_FLOAT_TYPE */ /* Points to memory space allocated as "spare", to be freed if we run out of memory. */ @@ -1345,8 +1343,6 @@ Float Allocation ***********************************************************************/ -#ifdef LISP_FLOAT_TYPE - /* We store float cells inside of float_blocks, allocating a new float_block with malloc whenever necessary. Float cells reclaimed by GC are put on a free list to be reallocated before allocating @@ -1431,8 +1427,6 @@ return val; } -#endif /* LISP_FLOAT_TYPE */ - /*********************************************************************** @@ -2031,7 +2025,6 @@ return new; } -#ifdef LISP_FLOAT_TYPE Lisp_Object make_pure_float (num) @@ -2069,8 +2062,6 @@ return new; } -#endif /* LISP_FLOAT_TYPE */ - Lisp_Object make_pure_vector (len) EMACS_INT len; @@ -2103,10 +2094,8 @@ if (CONSP (obj)) return pure_cons (XCAR (obj), XCDR (obj)); -#ifdef LISP_FLOAT_TYPE else if (FLOATP (obj)) return make_pure_float (XFLOAT_DATA (obj)); -#endif /* LISP_FLOAT_TYPE */ else if (STRINGP (obj)) return make_pure_string (XSTRING (obj)->data, XSTRING (obj)->size, STRING_BYTES (XSTRING (obj)), @@ -2417,12 +2406,8 @@ make_number (total_free_markers)); total[3] = Fcons (make_number (total_string_size), make_number (total_vector_size)); -#ifdef LISP_FLOAT_TYPE total[4] = Fcons (make_number (total_floats), make_number (total_free_floats)); -#else - total[4] = Fcons (make_number (0), make_number (0)); -#endif total[5] = Fcons (make_number (total_intervals), make_number (total_free_intervals)); total[6] = Fcons (make_number (total_strings), @@ -2885,11 +2870,9 @@ goto loop; } -#ifdef LISP_FLOAT_TYPE case Lisp_Float: XMARK (XFLOAT (obj)->type); break; -#endif /* LISP_FLOAT_TYPE */ case Lisp_Int: break; @@ -3057,11 +3040,9 @@ survives_p = XMARKBIT (XCAR (obj)); break; -#ifdef LISP_FLOAT_TYPE case Lisp_Float: survives_p = XMARKBIT (XFLOAT (obj)->type); break; -#endif /* LISP_FLOAT_TYPE */ default: abort (); @@ -3130,7 +3111,6 @@ total_free_conses = num_free; } -#ifdef LISP_FLOAT_TYPE /* Put all unmarked floats on free list */ { register struct float_block *fblk; @@ -3177,7 +3157,6 @@ total_floats = num_used; total_free_floats = num_free; } -#endif /* LISP_FLOAT_TYPE */ /* Put all unmarked intervals on free list */ { @@ -3499,9 +3478,7 @@ init_cons (); init_symbol (); init_marker (); -#ifdef LISP_FLOAT_TYPE init_float (); -#endif /* LISP_FLOAT_TYPE */ INIT_INTERVALS; #ifdef REL_ALLOC
--- a/src/bytecode.c Thu Feb 17 09:20:23 2000 +0000 +++ b/src/bytecode.c Thu Feb 17 09:45:46 2000 +0000 @@ -434,11 +434,9 @@ { #ifdef BYTE_CODE_SAFE if (top > stacke) - error ("Byte code stack overflow (byte compiler bug), pc %d, depth %d", - stack.pc - stack.byte_string_start, stacke - top); + abort (); else if (top < stack.bottom - 1) - error ("Byte code stack underflow (byte compiler bug), pc %d", - stack.pc - stack.byte_string_start); + abort (); #endif #ifdef BYTE_CODE_METER @@ -1042,7 +1040,6 @@ CHECK_NUMBER_OR_FLOAT_COERCE_MARKER (v1, 0); CHECK_NUMBER_OR_FLOAT_COERCE_MARKER (v2, 0); AFTER_POTENTIAL_GC (); -#ifdef LISP_FLOAT_TYPE if (FLOATP (v1) || FLOATP (v2)) { double f1, f2; @@ -1052,7 +1049,6 @@ TOP = (f1 == f2 ? Qt : Qnil); } else -#endif TOP = (XINT (v1) == XINT (v2) ? Qt : Qnil); break; } @@ -1532,15 +1528,11 @@ #ifdef BYTE_CODE_SAFE if (op < Bconstant) { - BEFORE_POTENTIAL_GC (); - error ("unknown bytecode %d (byte compiler bug)", op); - AFTER_POTENTIAL_GC (); + abort (); } if ((op -= Bconstant) >= const_length) { - BEFORE_POTENTIAL_GC (); - error ("no constant number %d (byte compiler bug)", op); - AFTER_POTENTIAL_GC (); + abort (); } PUSH (vectorp[op]); #else
--- a/src/config.in Thu Feb 17 09:20:23 2000 +0000 +++ b/src/config.in Thu Feb 17 09:45:46 2000 +0000 @@ -28,10 +28,6 @@ /* These are all defined in the top-level Makefile by configure. They're here only for reference. */ -/* Define LISP_FLOAT_TYPE if you want emacs to support floating-point - numbers. */ -#undef LISP_FLOAT_TYPE - /* Define GNU_MALLOC if you want to use the GNU memory allocator. */ #undef GNU_MALLOC
--- a/src/data.c Thu Feb 17 09:20:23 2000 +0000 +++ b/src/data.c Thu Feb 17 09:45:46 2000 +0000 @@ -25,17 +25,11 @@ #include "lisp.h" #include "puresize.h" #include "charset.h" - -#ifndef standalone #include "buffer.h" #include "keyboard.h" #include "frame.h" -#endif - #include "syssignal.h" -#ifdef LISP_FLOAT_TYPE - #ifdef STDC_HEADERS #include <float.h> #endif @@ -61,7 +55,6 @@ #endif #include <math.h> -#endif /* LISP_FLOAT_TYPE */ #if !defined (atof) extern double atof (); @@ -93,10 +86,8 @@ Lisp_Object Qrange_error, Qdomain_error, Qsingularity_error; Lisp_Object Qoverflow_error, Qunderflow_error; -#ifdef LISP_FLOAT_TYPE Lisp_Object Qfloatp; Lisp_Object Qnumberp, Qnumber_or_marker_p; -#endif static Lisp_Object Qinteger, Qsymbol, Qstring, Qcons, Qmarker, Qoverlay; static Lisp_Object Qfloat, Qwindow_configuration, Qwindow; @@ -252,10 +243,8 @@ return Qhash_table; return Qvector; -#ifdef LISP_FLOAT_TYPE case Lisp_Float: return Qfloat; -#endif default: abort (); @@ -506,7 +495,6 @@ return Qnil; } -#ifdef LISP_FLOAT_TYPE DEFUN ("floatp", Ffloatp, Sfloatp, 1, 1, 0, "Return t if OBJECT is a floating point number.") (object) @@ -516,7 +504,7 @@ return Qt; return Qnil; } -#endif /* LISP_FLOAT_TYPE */ + /* Extract and set components of lists */ @@ -1939,7 +1927,6 @@ double f1, f2; int floatp = 0; -#ifdef LISP_FLOAT_TYPE CHECK_NUMBER_OR_FLOAT_COERCE_MARKER (num1, 0); CHECK_NUMBER_OR_FLOAT_COERCE_MARKER (num2, 0); @@ -1949,10 +1936,6 @@ f1 = (FLOATP (num1)) ? XFLOAT_DATA (num1) : XINT (num1); f2 = (FLOATP (num2)) ? XFLOAT_DATA (num2) : XINT (num2); } -#else - CHECK_NUMBER_COERCE_MARKER (num1, 0); - CHECK_NUMBER_COERCE_MARKER (num2, 0); -#endif /* LISP_FLOAT_TYPE */ switch (comparison) { @@ -2045,7 +2028,6 @@ (number) register Lisp_Object number; { -#ifdef LISP_FLOAT_TYPE CHECK_NUMBER_OR_FLOAT (number, 0); if (FLOATP (number)) @@ -2054,9 +2036,6 @@ return Qt; return Qnil; } -#else - CHECK_NUMBER (number, 0); -#endif /* LISP_FLOAT_TYPE */ if (!XINT (number)) return Qt; @@ -2101,9 +2080,6 @@ { char buffer[VALBITS]; -#ifndef LISP_FLOAT_TYPE - CHECK_NUMBER (number, 0); -#else CHECK_NUMBER_OR_FLOAT (number, 0); if (FLOATP (number)) @@ -2113,7 +2089,6 @@ float_to_string (pigbuf, XFLOAT_DATA (number)); return build_string (pigbuf); } -#endif /* LISP_FLOAT_TYPE */ if (sizeof (int) == sizeof (EMACS_INT)) sprintf (buffer, "%d", XINT (number)); @@ -2187,10 +2162,8 @@ else if (*p == '+') p++; -#ifdef LISP_FLOAT_TYPE if (isfloat_string (p) && b == 10) return make_float (negative * atof (p)); -#endif /* LISP_FLOAT_TYPE */ while (1) { @@ -2237,15 +2210,11 @@ for (argnum = 0; argnum < nargs; argnum++) { val = args[argnum]; /* using args[argnum] as argument to CHECK_NUMBER_... */ -#ifdef LISP_FLOAT_TYPE CHECK_NUMBER_OR_FLOAT_COERCE_MARKER (val, argnum); if (FLOATP (val)) /* time to do serious math */ return (float_arith_driver ((double) accum, argnum, code, nargs, args)); -#else - CHECK_NUMBER_COERCE_MARKER (val, argnum); -#endif /* LISP_FLOAT_TYPE */ args[argnum] = val; /* runs into a compiler bug. */ next = XINT (args[argnum]); switch (SWITCH_ENUM_CAST (code)) @@ -2279,8 +2248,6 @@ #undef isnan #define isnan(x) ((x) != (x)) -#ifdef LISP_FLOAT_TYPE - Lisp_Object float_arith_driver (accum, argnum, code, nargs, args) double accum; @@ -2344,7 +2311,7 @@ return make_float (accum); } -#endif /* LISP_FLOAT_TYPE */ + DEFUN ("+", Fplus, Splus, 0, MANY, 0, "Return sum of any number of arguments, which are numbers or markers.") @@ -2436,18 +2403,12 @@ Lisp_Object val; EMACS_INT i1, i2; -#ifdef LISP_FLOAT_TYPE CHECK_NUMBER_OR_FLOAT_COERCE_MARKER (x, 0); CHECK_NUMBER_OR_FLOAT_COERCE_MARKER (y, 1); if (FLOATP (x) || FLOATP (y)) return fmod_float (x, y); -#else /* not LISP_FLOAT_TYPE */ - CHECK_NUMBER_COERCE_MARKER (x, 0); - CHECK_NUMBER_COERCE_MARKER (y, 1); -#endif /* not LISP_FLOAT_TYPE */ - i1 = XINT (x); i2 = XINT (y); @@ -2566,14 +2527,10 @@ (number) register Lisp_Object number; { -#ifdef LISP_FLOAT_TYPE CHECK_NUMBER_OR_FLOAT_COERCE_MARKER (number, 0); if (FLOATP (number)) return (make_float (1.0 + XFLOAT_DATA (number))); -#else - CHECK_NUMBER_COERCE_MARKER (number, 0); -#endif /* LISP_FLOAT_TYPE */ XSETINT (number, XINT (number) + 1); return number; @@ -2585,14 +2542,10 @@ (number) register Lisp_Object number; { -#ifdef LISP_FLOAT_TYPE CHECK_NUMBER_OR_FLOAT_COERCE_MARKER (number, 0); if (FLOATP (number)) return (make_float (-1.0 + XFLOAT_DATA (number))); -#else - CHECK_NUMBER_COERCE_MARKER (number, 0); -#endif /* LISP_FLOAT_TYPE */ XSETINT (number, XINT (number) - 1); return number; @@ -2660,11 +2613,9 @@ Qboundp = intern ("boundp"); Qfboundp = intern ("fboundp"); -#ifdef LISP_FLOAT_TYPE Qfloatp = intern ("floatp"); Qnumberp = intern ("numberp"); Qnumber_or_marker_p = intern ("number-or-marker-p"); -#endif /* LISP_FLOAT_TYPE */ Qchar_table_p = intern ("char-table-p"); Qvector_or_char_table_p = intern ("vector-or-char-table-p"); @@ -2770,7 +2721,6 @@ Fput (Qtext_read_only, Qerror_message, build_string ("Text is read-only")); -#ifdef LISP_FLOAT_TYPE Qrange_error = intern ("range-error"); Qdomain_error = intern ("domain-error"); Qsingularity_error = intern ("singularity-error"); @@ -2807,7 +2757,6 @@ staticpro (&Qsingularity_error); staticpro (&Qoverflow_error); staticpro (&Qunderflow_error); -#endif /* LISP_FLOAT_TYPE */ staticpro (&Qnil); staticpro (&Qt); @@ -2855,11 +2804,9 @@ staticpro (&Qmarkerp); staticpro (&Qbuffer_or_string_p); staticpro (&Qinteger_or_marker_p); -#ifdef LISP_FLOAT_TYPE staticpro (&Qfloatp); staticpro (&Qnumberp); staticpro (&Qnumber_or_marker_p); -#endif /* LISP_FLOAT_TYPE */ staticpro (&Qchar_table_p); staticpro (&Qvector_or_char_table_p); @@ -2924,9 +2871,7 @@ defsubr (&Sinteger_or_marker_p); defsubr (&Snumberp); defsubr (&Snumber_or_marker_p); -#ifdef LISP_FLOAT_TYPE defsubr (&Sfloatp); -#endif /* LISP_FLOAT_TYPE */ defsubr (&Snatnump); defsubr (&Ssymbolp); defsubr (&Skeywordp);
--- a/src/dispnew.c Thu Feb 17 09:20:23 2000 +0000 +++ b/src/dispnew.c Thu Feb 17 09:45:46 2000 +0000 @@ -5509,16 +5509,11 @@ CHECK_NUMBER (milliseconds, 1); usec = XINT (milliseconds) * 1000; -#ifdef LISP_FLOAT_TYPE { double duration = extract_float (seconds); sec = (int) duration; usec += (duration - sec) * 1000000; } -#else - CHECK_NUMBER (seconds, 0); - sec = XINT (seconds); -#endif #ifndef EMACS_HAS_USECS if (sec == 0 && usec != 0) @@ -5641,16 +5636,11 @@ CHECK_NUMBER (milliseconds, 1); usec = XINT (milliseconds) * 1000; -#ifdef LISP_FLOAT_TYPE { double duration = extract_float (seconds); sec = (int) duration; usec += (duration - sec) * 1000000; } -#else - CHECK_NUMBER (seconds, 0); - sec = XINT (seconds); -#endif #ifndef EMACS_HAS_USECS if (usec != 0 && sec == 0)
--- a/src/ecrt0.c Thu Feb 17 09:20:23 2000 +0000 +++ b/src/ecrt0.c Thu Feb 17 09:45:46 2000 +0000 @@ -347,9 +347,7 @@ _start () { #ifdef sun -#ifdef LISP_FLOAT_TYPE finitfp_(); -#endif #endif /* On 68000, _start pushes a6 onto stack */ start1 ();
--- a/src/editfns.c Thu Feb 17 09:20:23 2000 +0000 +++ b/src/editfns.c Thu Feb 17 09:45:46 2000 +0000 @@ -2963,7 +2963,6 @@ /* Would get MPV otherwise, since Lisp_Int's `point' to low memory. */ else if (INTEGERP (args[n]) && *format != 's') { -#ifdef LISP_FLOAT_TYPE /* The following loop assumes the Lisp type indicates the proper way to pass the argument. So make sure we have a flonum if the argument should @@ -2971,7 +2970,6 @@ if (*format == 'e' || *format == 'f' || *format == 'g') args[n] = Ffloat (args[n]); else -#endif if (*format != 'd' && *format != 'o' && *format != 'x' && *format != 'i' && *format != 'X' && *format != 'c') error ("Invalid format operation %%%c", *format); @@ -2990,14 +2988,12 @@ thissize = STRING_BYTES (XSTRING (args[n])); } } -#ifdef LISP_FLOAT_TYPE else if (FLOATP (args[n]) && *format != 's') { if (! (*format == 'e' || *format == 'f' || *format == 'g')) args[n] = Ftruncate (args[n], Qnil); thissize = 200; } -#endif else { /* Anything but a string, convert to a string using princ. */
--- a/src/emacs.c Thu Feb 17 09:20:23 2000 +0000 +++ b/src/emacs.c Thu Feb 17 09:45:46 2000 +0000 @@ -1404,9 +1404,7 @@ init_xdisp (); init_macros (); init_editfns (); -#ifdef LISP_FLOAT_TYPE init_floatfns (); -#endif #ifdef VMS init_vmsfns (); #endif /* VMS */
--- a/src/floatfns.c Thu Feb 17 09:20:23 2000 +0000 +++ b/src/floatfns.c Thu Feb 17 09:45:46 2000 +0000 @@ -49,8 +49,6 @@ #include "lisp.h" #include "syssignal.h" -#ifdef LISP_FLOAT_TYPE - #if STDC_HEADERS #include <float.h> #endif @@ -717,8 +715,6 @@ return val; } -#endif /* LISP_FLOAT_TYPE */ - /* the rounding functions */ @@ -737,7 +733,6 @@ CHECK_NUMBER_OR_FLOAT (divisor, 1); -#ifdef LISP_FLOAT_TYPE if (FLOATP (arg) || FLOATP (divisor)) { double f1, f2; @@ -751,7 +746,6 @@ FLOAT_TO_INT2 (f1, arg, name, arg, divisor); return arg; } -#endif i1 = XINT (arg); i2 = XINT (divisor); @@ -763,7 +757,6 @@ return arg; } -#ifdef LISP_FLOAT_TYPE if (FLOATP (arg)) { double d; @@ -771,7 +764,6 @@ IN_FLOAT (d = (*double_round) (XFLOAT_DATA (arg)), name, arg); FLOAT_TO_INT (d, arg, name, arg); } -#endif return arg; } @@ -881,7 +873,6 @@ "truncate"); } -#ifdef LISP_FLOAT_TYPE Lisp_Object fmod_float (x, y) @@ -1018,17 +1009,9 @@ in_float = 0; } -#else /* not LISP_FLOAT_TYPE */ - -init_floatfns () -{} - -#endif /* not LISP_FLOAT_TYPE */ - void syms_of_floatfns () { -#ifdef LISP_FLOAT_TYPE defsubr (&Sacos); defsubr (&Sasin); defsubr (&Satan); @@ -1066,7 +1049,6 @@ defsubr (&Sabs); defsubr (&Sfloat); defsubr (&Slogb); -#endif /* LISP_FLOAT_TYPE */ defsubr (&Sceiling); defsubr (&Sfloor); defsubr (&Sround);
--- a/src/fns.c Thu Feb 17 09:20:23 2000 +0000 +++ b/src/fns.c Thu Feb 17 09:45:46 2000 +0000 @@ -1852,10 +1852,8 @@ switch (XTYPE (o1)) { -#ifdef LISP_FLOAT_TYPE case Lisp_Float: return (extract_float (o1) == extract_float (o2)); -#endif case Lisp_Cons: if (!internal_equal (XCAR (o1), XCAR (o2), depth + 1))
--- a/src/lisp.h Thu Feb 17 09:20:23 2000 +0000 +++ b/src/lisp.h Thu Feb 17 09:45:46 2000 +0000 @@ -75,9 +75,7 @@ /* Cons. XCONS (object) points to a struct Lisp_Cons. */ Lisp_Cons, -#ifdef LISP_FLOAT_TYPE Lisp_Float, -#endif /* LISP_FLOAT_TYPE */ /* This is not a type code. It is for range checking. */ Lisp_Type_Limit @@ -1027,8 +1025,7 @@ struct Lisp_Kboard_Objfwd u_kboard_objfwd; }; -#ifdef LISP_FLOAT_TYPE -/* Optional Lisp floating point type */ +/* Lisp floating point type */ struct Lisp_Float { Lisp_Object type; /* essentially used for mark-bit @@ -1045,7 +1042,6 @@ #else #define XFLOAT_DATA(f) (XFLOAT (f)->data) #endif -#endif /* LISP_FLOAT_TYPE */ /* A character, declared with the following typedef, is a member of some character set associated with the current buffer. */ @@ -1168,13 +1164,8 @@ #define NILP(x) (XFASTINT (x) == XFASTINT (Qnil)) #define GC_NILP(x) GC_EQ (x, Qnil) -#ifdef LISP_FLOAT_TYPE #define NUMBERP(x) (INTEGERP (x) || FLOATP (x)) #define GC_NUMBERP(x) (GC_INTEGERP (x) || GC_FLOATP (x)) -#else -#define NUMBERP(x) (INTEGERP (x)) -#define GC_NUMBERP(x) (GC_INTEGERP (x)) -#endif #define NATNUMP(x) (INTEGERP (x) && XINT (x) >= 0) #define GC_NATNUMP(x) (GC_INTEGERP (x) && XINT (x) >= 0) @@ -1191,13 +1182,8 @@ #define CONSP(x) (XTYPE ((x)) == Lisp_Cons) #define GC_CONSP(x) (XGCTYPE ((x)) == Lisp_Cons) -#ifdef LISP_FLOAT_TYPE #define FLOATP(x) (XTYPE ((x)) == Lisp_Float) #define GC_FLOATP(x) (XGCTYPE ((x)) == Lisp_Float) -#else -#define FLOATP(x) (0) -#define GC_FLOATP(x) (0) -#endif #define VECTORP(x) (VECTORLIKEP (x) && !(XVECTOR (x)->size & PSEUDOVECTOR_FLAG)) #define GC_VECTORP(x) (GC_VECTORLIKEP (x) && !(XVECTOR (x)->size & PSEUDOVECTOR_FLAG)) #define OVERLAYP(x) (MISCP (x) && XMISCTYPE (x) == Lisp_Misc_Overlay) @@ -1318,8 +1304,6 @@ do { if (MARKERP ((x))) XSETFASTINT (x, marker_position (x)); \ else if (!INTEGERP ((x))) x = wrong_type_argument (Qinteger_or_marker_p, (x)); } while (0) -#ifdef LISP_FLOAT_TYPE - #define XFLOATINT(n) extract_float((n)) #define CHECK_FLOAT(x, i) \ @@ -1335,15 +1319,6 @@ else if (!INTEGERP (x) && !FLOATP (x)) \ x = wrong_type_argument (Qnumber_or_marker_p, (x)); } while (0) -#else /* Not LISP_FLOAT_TYPE */ - -#define CHECK_NUMBER_OR_FLOAT CHECK_NUMBER - -#define CHECK_NUMBER_OR_FLOAT_COERCE_MARKER CHECK_NUMBER_COERCE_MARKER - -#define XFLOATINT(n) XINT((n)) -#endif /* LISP_FLOAT_TYPE */ - #define CHECK_OVERLAY(x, i) \ do { if (!OVERLAYP ((x))) x = wrong_type_argument (Qoverlayp, (x));} while (0) @@ -1742,9 +1717,7 @@ extern Lisp_Object Qbuffer_or_string_p; extern Lisp_Object Qcdr; -#ifdef LISP_FLOAT_TYPE extern Lisp_Object Qfloatp, Qinteger_or_floatp, Qinteger_or_float_or_marker_p; -#endif /* LISP_FLOAT_TYPE */ extern Lisp_Object Qframep; @@ -1767,11 +1740,9 @@ EXFUN (Fsubrp, 1); EXFUN (Fchar_or_string_p, 1); EXFUN (Finteger_or_marker_p, 1); -#ifdef LISP_FLOAT_TYPE EXFUN (Ffloatp, 1); EXFUN (Finteger_or_floatp, 1); EXFUN (Finteger_or_float_or_marker_p, 1); -#endif /* LISP_FLOAT_TYPE */ EXFUN (Fcar, 1); EXFUN (Fcar_safe, 1); @@ -1986,10 +1957,8 @@ extern void syms_of_fns P_ ((void)); /* Defined in floatfns.c */ -#ifdef LISP_FLOAT_TYPE extern double extract_float P_ ((Lisp_Object)); EXFUN (Ffloat, 1); -#endif /* LISP_FLOAT_TYPE */ EXFUN (Ftruncate, 2); extern void init_floatfns P_ ((void)); extern void syms_of_floatfns P_ ((void)); @@ -2125,9 +2094,7 @@ extern Lisp_Object Qchar_table_extra_slots; extern struct Lisp_Vector *allocate_vectorlike P_ ((EMACS_INT)); extern int gc_in_progress; -#ifdef LISP_FLOAT_TYPE extern Lisp_Object make_float P_ ((double)); -#endif /* LISP_FLOAT_TYPE */ extern void display_malloc_warning P_ ((void)); extern int inhibit_garbage_collection P_ ((void)); extern void free_marker P_ ((Lisp_Object));
--- a/src/lread.c Thu Feb 17 09:20:23 2000 +0000 +++ b/src/lread.c Thu Feb 17 09:45:46 2000 +0000 @@ -31,15 +31,12 @@ #include <errno.h> #include "lisp.h" #include "intervals.h" - -#ifndef standalone #include "buffer.h" #include "charset.h" #include <epaths.h> #include "commands.h" #include "keyboard.h" #include "termhooks.h" -#endif #ifdef lint #include <sys/inode.h> @@ -60,9 +57,7 @@ #define X_OK 01 #endif -#ifdef LISP_FLOAT_TYPE #include <math.h> -#endif /* LISP_FLOAT_TYPE */ #ifdef HAVE_SETLOCALE #include <locale.h> @@ -408,9 +403,6 @@ input_method) int no_switch_frame, ascii_required, error_nonascii, input_method; { -#ifdef standalone - return make_number (getchar ()); -#else register Lisp_Object val, delayed_switch_frame; delayed_switch_frame = Qnil; @@ -471,7 +463,6 @@ unread_switch_frame = delayed_switch_frame; return val; -#endif } DEFUN ("read-char", Fread_char, Sread_char, 0, 2, 0, @@ -1130,8 +1121,6 @@ unbind_to (count, Qnil); } -#ifndef standalone - DEFUN ("eval-buffer", Feval_buffer, Seval_buffer, 0, 5, "", "Execute the current buffer as Lisp code.\n\ Programs can pass two arguments, BUFFER and PRINTFLAG.\n\ @@ -1246,7 +1235,6 @@ return unbind_to (count, Qnil); } -#endif /* standalone */ DEFUN ("read", Fread, Sread, 0, 1, 0, "Read one Lisp expression as text from STREAM, return as Lisp object.\n\ @@ -1272,10 +1260,8 @@ new_backquote_flag = 0; read_objects = Qnil; -#ifndef standalone if (EQ (stream, Qread_char)) return Fread_minibuffer (build_string ("Lisp expression: "), Qnil); -#endif if (STRINGP (stream)) return Fcar (Fread_from_string (stream, Qnil, Qnil)); @@ -2004,7 +1990,6 @@ case '.': { -#ifdef LISP_FLOAT_TYPE /* If a period is followed by a number, then we should read it as a floating point number. Otherwise, it denotes a dotted pair. */ @@ -2012,7 +1997,6 @@ UNREAD (next_char); if (! (next_char >= '0' && next_char <= '9')) -#endif { *pch = c; return Qnil; @@ -2035,11 +2019,6 @@ while (c > 040 && !(c == '\"' || c == '\'' || c == ';' || c == '?' || c == '(' || c == ')' -#ifndef LISP_FLOAT_TYPE - /* If we have floating-point support, then we need - to allow <digits><dot><digits>. */ - || c =='.' -#endif /* not LISP_FLOAT_TYPE */ || c == '[' || c == ']' || c == '#' )) { @@ -2086,17 +2065,13 @@ if (p1 != p) { while (p1 != p && (c = *p1) >= '0' && c <= '9') p1++; -#ifdef LISP_FLOAT_TYPE /* Integers can have trailing decimal points. */ if (p1 > read_buffer && p1 < p && *p1 == '.') p1++; -#endif if (p1 == p) /* It is an integer. */ { -#ifdef LISP_FLOAT_TYPE if (p1[-1] == '.') p1[-1] = '\0'; -#endif if (sizeof (int) == sizeof (EMACS_INT)) XSETINT (val, atoi (read_buffer)); else if (sizeof (long) == sizeof (EMACS_INT)) @@ -2106,7 +2081,6 @@ return val; } } -#ifdef LISP_FLOAT_TYPE if (isfloat_string (read_buffer)) { /* Compute NaN and infinities using 0.0 in a variable, @@ -2139,7 +2113,6 @@ return make_float (negative ? - value : value); } -#endif } if (uninterned_symbol) @@ -2271,8 +2244,6 @@ } -#ifdef LISP_FLOAT_TYPE - #define LEAD_INT 1 #define DOT_CHAR 2 #define TRAIL_INT 4 @@ -2342,7 +2313,7 @@ || state == (LEAD_INT|DOT_CHAR|TRAIL_INT|E_CHAR|EXP_INT) || state == (DOT_CHAR|TRAIL_INT|E_CHAR|EXP_INT))); } -#endif /* LISP_FLOAT_TYPE */ + static Lisp_Object read_vector (readcharfun, bytecodeflag) @@ -3022,8 +2993,6 @@ staticpro (address); } -#ifndef standalone - /* Similar but define a variable whose value is the Lisp Object stored in the current buffer. address is the address of the slot in the buffer that is current now. */ @@ -3054,7 +3023,6 @@ abort (); } -#endif /* standalone */ /* Similar but define a variable whose value is the Lisp Object stored at a particular offset in the current kboard object. */
--- a/src/print.c Thu Feb 17 09:20:23 2000 +0000 +++ b/src/print.c Thu Feb 17 09:45:46 2000 +0000 @@ -40,7 +40,6 @@ /* These are used to print like we read. */ extern Lisp_Object Qbackquote, Qcomma, Qcomma_at, Qcomma_dot, Qfunction; -#ifdef LISP_FLOAT_TYPE Lisp_Object Vfloat_output_format, Qfloat_output_format; /* Work around a problem that happens because math.h on hpux 7 @@ -89,8 +88,6 @@ #define DOUBLE_DIGITS_BOUND ((int) ceil (log10 (pow (FLT_RADIX, DBL_MANT_DIG)))) #endif -#endif /* LISP_FLOAT_TYPE */ - /* Avoid actual stack overflow in print. */ int print_depth; @@ -914,7 +911,6 @@ UNGCPRO; } -#ifdef LISP_FLOAT_TYPE /* * The buffer should be at least as large as the max string size of the @@ -1053,7 +1049,7 @@ } } } -#endif /* LISP_FLOAT_TYPE */ + static void print (obj, printcharfun, escapeflag) @@ -1269,7 +1265,6 @@ strout (buf, -1, -1, printcharfun, 0); break; -#ifdef LISP_FLOAT_TYPE case Lisp_Float: { char pigbuf[350]; /* see comments in float_to_string */ @@ -1278,7 +1273,6 @@ strout (pigbuf, -1, -1, printcharfun, 0); } break; -#endif case Lisp_String: if (!escapeflag) @@ -1886,7 +1880,6 @@ Qstandard_output = intern ("standard-output"); staticpro (&Qstandard_output); -#ifdef LISP_FLOAT_TYPE DEFVAR_LISP ("float-output-format", &Vfloat_output_format, "The format descriptor string used to print floats.\n\ This is a %-spec like those accepted by `printf' in C,\n\ @@ -1905,7 +1898,6 @@ Vfloat_output_format = Qnil; Qfloat_output_format = intern ("float-output-format"); staticpro (&Qfloat_output_format); -#endif /* LISP_FLOAT_TYPE */ DEFVAR_LISP ("print-length", &Vprint_length, "Maximum length of list to print before abbreviating.\n\