/* Evaluator for GNU Emacs Lisp interpreter.
Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1999, 2000, 2001,
- 2002, 2004, 2005 Free Software Foundation, Inc.
+ 2002, 2003, 2004, 2005 Free Software Foundation, Inc.
This file is part of GNU Emacs.
register Lisp_Object sym, tem, tail;
sym = Fcar (args);
- if (SYMBOL_CONSTANT_P (sym))
- {
- /* For updward compatibility, allow (defvar :foo (quote :foo)). */
- tem = Fcar (Fcdr (args));
- if (! (CONSP (tem)
- && EQ (XCAR (tem), Qquote)
- && CONSP (XCDR (tem))
- && EQ (XCAR (XCDR (tem)), sym)))
- error ("Constant symbol `%s' specified in defvar",
- SDATA (SYMBOL_NAME (sym)));
- }
-
tail = Fcdr (args);
if (!NILP (Fcdr (Fcdr (tail))))
error ("Too many arguments");
tem = Fdefault_boundp (sym);
if (!NILP (tail))
{
+ if (SYMBOL_CONSTANT_P (sym))
+ {
+ /* For upward compatibility, allow (defvar :foo (quote :foo)). */
+ Lisp_Object tem = Fcar (tail);
+ if (! (CONSP (tem)
+ && EQ (XCAR (tem), Qquote)
+ && CONSP (XCDR (tem))
+ && EQ (XCAR (XCDR (tem)), sym)))
+ error ("Constant symbol `%s' specified in defvar",
+ SDATA (SYMBOL_NAME (sym)));
+ }
+
if (NILP (tem))
Fset_default (sym, Feval (Fcar (tail)));
else
return form;
QUIT;
- if (consing_since_gc > gc_cons_combined_threshold)
+ if (consing_since_gc > gc_cons_threshold
+ && consing_since_gc > gc_relative_threshold)
{
GCPRO1 (form);
Fgarbage_collect ();
register int i;
QUIT;
- if (consing_since_gc > gc_cons_combined_threshold)
+ if (consing_since_gc > gc_cons_threshold
+ && consing_since_gc > gc_relative_threshold)
Fgarbage_collect ();
if (++lisp_eval_depth > max_lisp_eval_depth)