From a7f96a358b12d90b44fa11ac65caf24fd164ad6d Mon Sep 17 00:00:00 2001 From: "Kim F. Storm" Date: Fri, 10 Feb 2006 00:00:31 +0000 Subject: * data.c (Findirect_function): Add NOERROR arg. All callers changed to pass Qnil for NOERROR. * keymap.c (current_minor_maps_error): Remove. (current_minor_maps): Pass Qt for NOERROR to Findirect_function instead of using internal_condition_case_1+current_minor_maps_error. --- src/data.c | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) (limited to 'src/data.c') diff --git a/src/data.c b/src/data.c index 278105ba99..7919021d06 100644 --- a/src/data.c +++ b/src/data.c @@ -1927,15 +1927,16 @@ indirect_function (object) return hare; } -DEFUN ("indirect-function", Findirect_function, Sindirect_function, 1, 1, 0, +DEFUN ("indirect-function", Findirect_function, Sindirect_function, 1, 2, 0, doc: /* Return the function at the end of OBJECT's function chain. If OBJECT is a symbol, follow all function indirections and return the final function binding. If OBJECT is not a symbol, just return it. -Signal a void-function error if the final symbol is unbound. +If optional arg NOERROR is nil, signal a void-function error if +the final symbol is unbound. Otherwise, just return nil is unbound. Signal a cyclic-function-indirection error if there is a loop in the function chain of symbols. */) - (object) +(object, noerror) register Lisp_Object object; { Lisp_Object result; @@ -1943,7 +1944,9 @@ function chain of symbols. */) result = indirect_function (object); if (EQ (result, Qunbound)) - return Fsignal (Qvoid_function, Fcons (object, Qnil)); + return (NILP (noerror) + ? Fsignal (Qvoid_function, Fcons (object, Qnil)) + : Qnil); return result; } -- cgit v1.2.3