*** empty log message ***
[bpt/emacs.git] / src / eval.c
index f549f9d..c4fcc80 100644 (file)
@@ -1,5 +1,5 @@
 /* Evaluator for GNU Emacs Lisp interpreter.
-   Copyright (C) 1985, 1986, 1987 Free Software Foundation, Inc.
+   Copyright (C) 1985, 1986, 1987, 1992 Free Software Foundation, Inc.
 
 This file is part of GNU Emacs.
 
@@ -26,6 +26,7 @@ the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.  */
 
 #ifndef standalone
 #include "commands.h"
+#include "keyboard.h"
 #else
 #define INTERACTIVE 1
 #endif
@@ -623,6 +624,10 @@ Each VALUEFORM can refer to the symbols already bound by this VARLIST.")
       elt = Fcar (varlist);
       if (XTYPE (elt) == Lisp_Symbol)
        specbind (elt, Qnil);
+      else if (! NILP (Fcdr (Fcdr (elt))))
+       Fsignal (Qerror,
+                Fcons (build_string ("`let' bindings can have only one value-form"),
+                       elt));
       else
        {
          val = Feval (Fcar (Fcdr (elt)));
@@ -667,6 +672,10 @@ All the VALUEFORMs are evalled before any symbols are bound.")
       elt = Fcar (varlist);
       if (XTYPE (elt) == Lisp_Symbol)
        temps [argnum++] = Qnil;
+      else if (! NILP (Fcdr (Fcdr (elt))))
+       Fsignal (Qerror,
+                Fcons (build_string ("`let' bindings can have only one value-form"),
+                       elt));
       else
        temps [argnum++] = Feval (Fcar (Fcdr (elt)));
       gcpro2.nvars = argnum;
@@ -1498,8 +1507,11 @@ DEFUN ("eval", Feval, Seval, 1, 1, 0,
          goto done;
 
        default:
-         error ("Ffuncall doesn't handle that number of arguments.");
-         goto done;
+         /* Someone has created a subr that takes more arguments than
+            is supported by this code.  We need to either rewrite the
+            subr to use a different argument protocol, or add more
+            cases to this switch.  */
+         abort ();
        }
     }
   if (XTYPE (fun) == Lisp_Compiled)
@@ -1836,7 +1848,11 @@ Thus, (funcall 'cons 'x 'y) returns (x . y).")
          goto done;
 
        default:
-         error ("funcall: this number of args not handled.");
+
+         /* If a subr takes more than 6 arguments without using MANY
+            or UNEVALLED, we need to extend this function to support it. 
+            Until this is done, there is no way to call the function.  */
+         abort ();
        }
     }
   if (XTYPE (fun) == Lisp_Compiled)