diff options
author | Richard M. Stallman <rms@gnu.org> | 1994-03-02 03:46:54 +0000 |
---|---|---|
committer | Richard M. Stallman <rms@gnu.org> | 1994-03-02 03:46:54 +0000 |
commit | 9f5bb4b91331966e7bf770b08b90cc3e2648cecf (patch) | |
tree | f39cb9615d147d3cc46cd1cf6fc38dc10652544c /src/eval.c | |
parent | bf092444c61a42d28b14c73faf0d33a51029fbe1 (diff) | |
download | emacs-9f5bb4b91331966e7bf770b08b90cc3e2648cecf.tar.gz |
(Fsignal): If DATA is memory_signal_data, don't add to it.
(Fsignal): Record the clause in chosen_clause.
(Fcondition_case, internal_condition_case): Look there.
(internal_condition_case_1): Look there.
Diffstat (limited to 'src/eval.c')
-rw-r--r-- | src/eval.c | 17 |
1 files changed, 12 insertions, 5 deletions
diff --git a/src/eval.c b/src/eval.c index 9e5a33d9775..02590e6e938 100644 --- a/src/eval.c +++ b/src/eval.c @@ -1034,8 +1034,8 @@ See also the function `signal' for more info.") if (_setjmp (c.jmp)) { if (!NILP (h.var)) - specbind (h.var, Fcdr (c.val)); - val = Fprogn (Fcdr (Fcar (c.val))); + specbind (h.var, c.val); + val = Fprogn (Fcdr (h.chosen_clause)); /* Note that this just undoes the binding of h.var; whoever longjumped to us unwound the stack to c.pdlcount before @@ -1078,7 +1078,7 @@ internal_condition_case (bfun, handlers, hfun) c.gcpro = gcprolist; if (_setjmp (c.jmp)) { - return (*hfun) (Fcdr (c.val)); + return (*hfun) (c.val); } c.next = catchlist; catchlist = &c; @@ -1115,7 +1115,7 @@ internal_condition_case_1 (bfun, arg, handlers, hfun) c.gcpro = gcprolist; if (_setjmp (c.jmp)) { - return (*hfun) (Fcdr (c.val)); + return (*hfun) (c.val); } c.next = catchlist; catchlist = &c; @@ -1190,9 +1190,16 @@ See also the function `condition-case'.") if (!NILP (clause)) { + Lisp_Object unwind_data; struct handler *h = handlerlist; + handlerlist = allhandlers; - unwind_to_catch (h->tag, Fcons (clause, Fcons (error_symbol, data))); + if (data == memory_signal_data) + unwind_data = memory_signal_data; + else + unwind_data = Fcons (error_symbol, data); + h->chosen_clause = clause; + unwind_to_catch (h->tag, unwind_data); } } |