]> code.delx.au - gnu-emacs/commitdiff
Remove `LISP_FLOAT_TYPE' and `standalone'.
authorGerd Moellmann <gerd@gnu.org>
Thu, 17 Feb 2000 09:45:46 +0000 (09:45 +0000)
committerGerd Moellmann <gerd@gnu.org>
Thu, 17 Feb 2000 09:45:46 +0000 (09:45 +0000)
14 files changed:
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

index 84317d1f28b65ff0568efb4e42d82492f7bdc994..469d948d185dcb61b5e16400825cb8afde4ba4d5 100644 (file)
@@ -127,11 +127,7 @@ CC = C_COMPILER
 #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 @@ otherobj= $(termcapobj) lastfile.o $(mallocobj) $(allocaobj) $(widgetobj)
 #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 \
index feb1a5b665fad75e167c802ebb2afcaf9f291ed0..8152ad2bf1ae308ef20f98f03a596637e019b58b 100644 (file)
@@ -151,9 +151,7 @@ int undo_strong_limit;
 
 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 @@ make_uninit_multibyte_string (nchars, nbytes)
                           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 @@ make_float (float_value)
   return val;
 }
 
-#endif /* LISP_FLOAT_TYPE */
-
 
 \f
 /***********************************************************************
@@ -2031,7 +2025,6 @@ pure_cons (car, cdr)
   return new;
 }
 
-#ifdef LISP_FLOAT_TYPE
 
 Lisp_Object
 make_pure_float (num)
@@ -2069,8 +2062,6 @@ make_pure_float (num)
   return new;
 }
 
-#endif /* LISP_FLOAT_TYPE */
-
 Lisp_Object
 make_pure_vector (len)
      EMACS_INT len;
@@ -2103,10 +2094,8 @@ Does not copy symbols.  Copies strings without text properties.")
 
   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 @@ Garbage collection happens automatically if you cons more than\n\
                    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 @@ mark_object (argptr)
        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_gc_p (obj)
       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 @@ gc_sweep ()
     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 @@ gc_sweep ()
     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_alloc_once ()
   init_cons ();
   init_symbol ();
   init_marker ();
-#ifdef LISP_FLOAT_TYPE
   init_float ();
-#endif /* LISP_FLOAT_TYPE */
   INIT_INTERVALS;
 
 #ifdef REL_ALLOC
index 52a0dba31d5c67b9d248c4b08b164ea752a337ca..14a93f18f8116ef801a97380baecb5fee58603df 100644 (file)
@@ -434,11 +434,9 @@ If the third argument is incorrect, Emacs may crash.")
     {
 #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 @@ If the third argument is incorrect, Emacs may crash.")
            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 @@ If the third argument is incorrect, Emacs may crash.")
                TOP = (f1 == f2 ? Qt : Qnil);
              }
            else
-#endif
              TOP = (XINT (v1) == XINT (v2) ? Qt : Qnil);
            break;
          }
@@ -1532,15 +1528,11 @@ If the third argument is incorrect, Emacs may crash.")
 #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
index 72928759558077b46d1d24544743dae25db076ad..177485fcdb368a1e9194de654d57702bb072961b 100644 (file)
@@ -28,10 +28,6 @@ Boston, MA 02111-1307, USA.  */
 /* 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
 
index 669efa5802e2a56eb5ffcb42e3d1eeba88ab3c5a..ce9de8c5b23ff1e6304b7f0dade949de88df1ee8 100644 (file)
@@ -25,17 +25,11 @@ Boston, MA 02111-1307, USA.  */
 #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 @@ Boston, MA 02111-1307, USA.  */
 #endif
 
 #include <math.h>
-#endif /* LISP_FLOAT_TYPE */
 
 #if !defined (atof)
 extern double atof ();
@@ -93,10 +86,8 @@ Lisp_Object Qad_advice_info, Qad_activate_internal;
 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 @@ for example, (type-of 1) returns `integer'.")
        return Qhash_table;
       return Qvector;
 
-#ifdef LISP_FLOAT_TYPE
     case Lisp_Float:
       return Qfloat;
-#endif
 
     default:
       abort ();
@@ -506,7 +495,6 @@ DEFUN ("number-or-marker-p", Fnumber_or_marker_p,
   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 @@ DEFUN ("floatp", Ffloatp, Sfloatp, 1, 1, 0,
     return Qt;
   return Qnil;
 }
-#endif /* LISP_FLOAT_TYPE */
+
 \f
 /* Extract and set components of lists */
 
@@ -1939,7 +1927,6 @@ arithcompare (num1, num2, comparison)
   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 @@ arithcompare (num1, num2, comparison)
       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 @@ DEFUN ("zerop", Fzerop, Szerop, 1, 1, 0, "Return t if NUMBER is zero.")
   (number)
      register Lisp_Object number;
 {
-#ifdef LISP_FLOAT_TYPE
   CHECK_NUMBER_OR_FLOAT (number, 0);
 
   if (FLOATP (number))
@@ -2054,9 +2036,6 @@ DEFUN ("zerop", Fzerop, Szerop, 1, 1, 0, "Return t if NUMBER is zero.")
        return Qt;
       return Qnil;
     }
-#else
-  CHECK_NUMBER (number, 0);
-#endif /* LISP_FLOAT_TYPE */
 
   if (!XINT (number))
     return Qt;
@@ -2101,9 +2080,6 @@ NUMBER may be an integer or a floating point number.")
 {
   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 @@ NUMBER may be an integer or a floating point number.")
       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 @@ If the base used is not 10, floating point is not recognized.")
   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 @@ arith_driver (code, nargs, args)
   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 @@ arith_driver (code, nargs, args)
 #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 @@ float_arith_driver (accum, argnum, code, nargs, args)
 
   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 @@ Both X and Y must be numbers or markers.")
   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 @@ Markers are converted to integers.")
   (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 @@ Markers are converted to integers.")
   (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 @@ syms_of_data ()
   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 @@ syms_of_data ()
   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 @@ syms_of_data ()
   staticpro (&Qsingularity_error);
   staticpro (&Qoverflow_error);
   staticpro (&Qunderflow_error);
-#endif /* LISP_FLOAT_TYPE */
 
   staticpro (&Qnil);
   staticpro (&Qt);
@@ -2855,11 +2804,9 @@ syms_of_data ()
   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 @@ A keyword symbol is a symbol whose name starts with a colon (`:').");
   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);
index 9bf8088caffaf5b69ca4646900a4d2aa33e4bed3..6592d703610dbdb31585353e3930fc3678c206a2 100644 (file)
@@ -5509,16 +5509,11 @@ Emacs was built without floating point support.\n\
     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 @@ Value is t if waited the full time with no input arriving.")
     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)
index a9c7f2891736927e1b472b2ea35891a94887f44d..ac23259de4fbf703cdf77f3168d3a2371ea2469a 100644 (file)
@@ -347,9 +347,7 @@ static foo () {
 _start ()
 {
 #ifdef sun
-#ifdef LISP_FLOAT_TYPE
   finitfp_();
-#endif
 #endif     
 /* On 68000, _start pushes a6 onto stack  */
   start1 ();
index fcc59979fe131894dec1da0c19e3b6cfc583201a..4e25655f492e5602069b4f9cabb220e9a05448f1 100644 (file)
@@ -2963,7 +2963,6 @@ Use %% to put a single % into the output.")
        /* 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 @@ Use %% to put a single % into the output.")
            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 @@ Use %% to put a single % into the output.")
                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.  */
index dd2e4b10f3f1d6d66264cc892cace2672c8a55f2..0dc6e07fb30eeafcbaba47ccd96800e6c1966acc 100644 (file)
@@ -1404,9 +1404,7 @@ main (argc, argv, envp)
   init_xdisp ();
   init_macros ();
   init_editfns ();
-#ifdef LISP_FLOAT_TYPE
   init_floatfns ();
-#endif
 #ifdef VMS
   init_vmsfns ();
 #endif /* VMS */
index ebe1b7de43c5b4572447f2e4ab1bb66081f6acd2..d6cbb876e37c785dbff4186ea3c130b6b5275473 100644 (file)
@@ -49,8 +49,6 @@ Boston, MA 02111-1307, USA.  */
 #include "lisp.h"
 #include "syssignal.h"
 
-#ifdef LISP_FLOAT_TYPE
-
 #if STDC_HEADERS
 #include <float.h>
 #endif
@@ -717,8 +715,6 @@ This is the same as the exponent of a float.")
   return val;
 }
 
-#endif /* LISP_FLOAT_TYPE */
-
 
 /* the rounding functions  */
 
@@ -737,7 +733,6 @@ rounding_driver (arg, divisor, double_round, int_round2, name)
 
       CHECK_NUMBER_OR_FLOAT (divisor, 1);
 
-#ifdef LISP_FLOAT_TYPE
       if (FLOATP (arg) || FLOATP (divisor))
        {
          double f1, f2;
@@ -751,7 +746,6 @@ rounding_driver (arg, divisor, double_round, int_round2, name)
          FLOAT_TO_INT2 (f1, arg, name, arg, divisor);
          return arg;
        }
-#endif
 
       i1 = XINT (arg);
       i2 = XINT (divisor);
@@ -763,7 +757,6 @@ rounding_driver (arg, divisor, double_round, int_round2, name)
       return arg;
     }
 
-#ifdef LISP_FLOAT_TYPE
   if (FLOATP (arg))
     {
       double d;
@@ -771,7 +764,6 @@ rounding_driver (arg, divisor, double_round, int_round2, name)
       IN_FLOAT (d = (*double_round) (XFLOAT_DATA (arg)), name, arg);
       FLOAT_TO_INT (d, arg, name, arg);
     }
-#endif
 
   return arg;
 }
@@ -881,7 +873,6 @@ With optional DIVISOR, truncate ARG/DIVISOR.")
                          "truncate");
 }
 
-#ifdef LISP_FLOAT_TYPE
 
 Lisp_Object
 fmod_float (x, y)
@@ -1018,17 +1009,9 @@ init_floatfns ()
   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 @@ syms_of_floatfns ()
   defsubr (&Sabs);
   defsubr (&Sfloat);
   defsubr (&Slogb);
-#endif /* LISP_FLOAT_TYPE */
   defsubr (&Sceiling);
   defsubr (&Sfloor);
   defsubr (&Sround);
index 9ac0bbadf701777a70016dbea0160da560a063a9..e6ff683594765d95c7c6f61de5ee53913d6d3338 100644 (file)
--- a/src/fns.c
+++ b/src/fns.c
@@ -1852,10 +1852,8 @@ internal_equal (o1, o2, depth)
 
   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))
index fe2e787b388d95f9fd7ced8b27d6042f09291975..a826e35870e37ea918aecc637ba101f255877f99 100644 (file)
@@ -75,9 +75,7 @@ enum Lisp_Type
     /* 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 @@ union Lisp_Misc
     struct Lisp_Kboard_Objfwd u_kboard_objfwd;
   };
 \f
-#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 @@ struct Lisp_Float
 #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 @@ typedef unsigned char UCHAR;
 #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 @@ typedef unsigned char UCHAR;
 #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 @@ typedef unsigned char UCHAR;
   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 @@ typedef unsigned char UCHAR;
   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 Qboundp, Qfboundp;
 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 (Fmarkerp, 1);
 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 map_char_table P_ ((void (*) (Lisp_Object, Lisp_Object, Lisp_Object)
 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 make_sub_char_table P_ ((Lisp_Object));
 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));
index efc2b3149b2271205d9fe4f0bc0684d0b490311b..8b2564c379264d5885ce5d88fbc54e6518cbaf9c 100644 (file)
@@ -31,15 +31,12 @@ Boston, MA 02111-1307, USA.  */
 #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 @@ Boston, MA 02111-1307, USA.  */
 #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 @@ read_filtered_event (no_switch_frame, ascii_required, error_nonascii,
                     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 @@ read_filtered_event (no_switch_frame, ascii_required, error_nonascii,
     unread_switch_frame = delayed_switch_frame;
 
   return val;
-#endif
 }
 
 DEFUN ("read-char", Fread_char, Sread_char, 0, 2, 0,
@@ -1130,8 +1121,6 @@ readevalloop (readcharfun, stream, sourcename, evalfun, printflag, unibyte, read
   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 @@ This function does not move point.")
   return unbind_to (count, Qnil);
 }
 
-#endif /* standalone */
 \f
 DEFUN ("read", Fread, Sread, 0, 1, 0,
   "Read one Lisp expression as text from STREAM, return as Lisp object.\n\
@@ -1272,10 +1260,8 @@ STREAM or the value of `standard-input' may be:\n\
   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 @@ read1 (readcharfun, pch, first_in_list)
 
     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 @@ read1 (readcharfun, pch, first_in_list)
        UNREAD (next_char);
 
        if (! (next_char >= '0' && next_char <= '9'))
-#endif
          {
            *pch = c;
            return Qnil;
@@ -2035,11 +2019,6 @@ read1 (readcharfun, pch, first_in_list)
          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 @@ read1 (readcharfun, pch, first_in_list)
            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 @@ read1 (readcharfun, pch, first_in_list)
                    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 @@ read1 (readcharfun, pch, first_in_list)
 
                return make_float (negative ? - value : value);
              }
-#endif
          }
 
        if (uninterned_symbol)
@@ -2271,8 +2244,6 @@ substitute_in_interval (interval, arg)
 }
 
 \f
-#ifdef LISP_FLOAT_TYPE
-
 #define LEAD_INT 1
 #define DOT_CHAR 2
 #define TRAIL_INT 4
@@ -2342,7 +2313,7 @@ isfloat_string (cp)
              || state == (LEAD_INT|DOT_CHAR|TRAIL_INT|E_CHAR|EXP_INT)
              || state == (DOT_CHAR|TRAIL_INT|E_CHAR|EXP_INT)));
 }
-#endif /* LISP_FLOAT_TYPE */
+
 \f
 static Lisp_Object
 read_vector (readcharfun, bytecodeflag)
@@ -3022,8 +2993,6 @@ defvar_lisp (namestring, address)
   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 @@ defvar_per_buffer (namestring, address, type, doc)
     abort ();
 }
 
-#endif /* standalone */
 
 /* Similar but define a variable whose value is the Lisp Object stored
    at a particular offset in the current kboard object.  */
index 2d1f13aadd550874d36f4e9404ff53154fe5d9aa..25e7f0a91ed0a4c281bcca34b239d4c0becaff9c 100644 (file)
@@ -40,7 +40,6 @@ Lisp_Object Qtemp_buffer_setup_hook;
 /* 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 @@ Lisp_Object Vfloat_output_format, Qfloat_output_format;
 #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 @@ print_error_message (data, stream)
   UNGCPRO;
 }
 \f
-#ifdef LISP_FLOAT_TYPE
 
 /*
  * The buffer should be at least as large as the max string size of the
@@ -1053,7 +1049,7 @@ float_to_string (buf, data)
        }
     }
 }
-#endif /* LISP_FLOAT_TYPE */
+
 \f
 static void
 print (obj, printcharfun, escapeflag)
@@ -1269,7 +1265,6 @@ print_object (obj, printcharfun, escapeflag)
       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 @@ print_object (obj, printcharfun, escapeflag)
        strout (pigbuf, -1, -1, printcharfun, 0);
       }
       break;
-#endif
 
     case Lisp_String:
       if (!escapeflag)
@@ -1886,7 +1880,6 @@ or the symbol t (output appears in the echo area).");
   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 @@ that represents the number without losing information.");
   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\