int specpdl_depth_counter;
/* Maximum size allowed for specpdl allocation */
-int max_specpdl_size;
+Fixnum max_specpdl_size;
/* Depth in Lisp evaluations and function calls. */
static int lisp_eval_depth;
/* Maximum allowed depth in Lisp evaluations and function calls. */
-int max_lisp_eval_depth;
+Fixnum max_lisp_eval_depth;
/* Nonzero means enter debugger before next function call */
static int debug_on_next_call;
if (EQ (tem, Qt) || EQ (tem, Qmacro))
{
/* Yes, load it and try again. */
+ /* do_autoload GCPROs both arguments */
do_autoload (def, sym);
continue;
}
#ifdef DEFEND_AGAINST_THROW_RECURSION
/* die if we recurse more than is reasonable */
if (++throw_level > 20)
- abort();
+ ABORT();
#endif
/* If bomb_out_p is t, this is being called from Fsignal as a
/* let's not use stderr_out() here, because that does a bunch of
things that might not be safe yet. */
fprintf (stderr, "Error before initialization is complete!\n");
- abort ();
+ ABORT ();
}
if (gc_in_progress || in_display)
/* This is one of many reasons why you can't run lisp code from redisplay.
There is no sensible way to handle errors there. */
- abort ();
+ ABORT ();
conditions = Fget (sig, Qerror_conditions, Qnil);
warn_when_safe_lispobj (Vcurrent_warning_class, Qwarning,
Fcons (error_symbol, data));
Fthrow (Qunbound_suspended_errors_tag, Qnil);
- abort (); /* Better not get here! */
+ ABORT (); /* Better not get here! */
}
RETURN_UNGCPRO (signal_1 (error_symbol, data));
}
{
final = indirect_function (cmd, 1);
if (CONSP (final) && EQ (Fcar (final), Qautoload))
- do_autoload (final, cmd);
+ {
+ /* do_autoload GCPROs both arguments */
+ do_autoload (final, cmd);
+ }
else
break;
}
/* This function can GC */
int speccount = specpdl_depth();
Lisp_Object fun = funname;
- struct gcpro gcpro1, gcpro2;
+ struct gcpro gcpro1, gcpro2, gcpro3;
CHECK_SYMBOL (funname);
- GCPRO2 (fun, funname);
+ GCPRO3 (fun, funname, fundef);
/* Value saved here is to be restored into Vautoload_queue */
record_unwind_protect (un_autoload, Vautoload_queue);
if (EQ (funcar, Qautoload))
{
+ /* do_autoload GCPROs both arguments */
do_autoload (fun, original_fun);
goto retry;
}
}
\f
+/* #### Why is Feval so anal about GCPRO, Ffuncall so cavalier? */
DEFUN ("funcall", Ffuncall, 1, MANY, 0, /*
Call first argument as a function, passing the remaining arguments to it.
Thus, (funcall 'cons 'x 'y) returns (x . y).
if (fun_nargs == max_args) /* Optimize for the common case */
{
funcall_subr:
- FUNCALL_SUBR (val, subr, fun_args, max_args);
+ {
+ /* The "extra" braces placate GCC 2.95.4. */
+ FUNCALL_SUBR (val, subr, fun_args, max_args);
+ }
}
else if (fun_nargs < subr->min_args)
{
}
else if (EQ (funcar, Qautoload))
{
+ /* do_autoload GCPROs both arguments */
do_autoload (fun, args[0]);
goto retry;
}
}
else if (EQ (funcar, Qautoload))
{
- struct gcpro gcpro1;
-
- GCPRO1 (function);
+ /* do_autoload GCPROs both arguments */
do_autoload (function, orig_function);
- UNGCPRO;
function = orig_function;
goto retry;
}
#define min_max_specpdl_size 400
void
-grow_specpdl (size_t reserved)
+grow_specpdl (EMACS_INT reserved)
{
- size_t size_needed = specpdl_depth() + reserved;
+ EMACS_INT size_needed = specpdl_depth() + reserved;
if (size_needed >= max_specpdl_size)
{
if (max_specpdl_size < min_max_specpdl_size)
Fset (symbol, value);
}
+/* Note: As long as the unwind-protect exists, its arg is automatically
+ GCPRO'd. */
+
void
record_unwind_protect (Lisp_Object (*function) (Lisp_Object arg),
Lisp_Object arg)