diff options
| author | Philipp Stephani <phst@google.com> | 2019-04-19 01:04:55 +0200 |
|---|---|---|
| committer | Philipp Stephani <phst@google.com> | 2019-04-19 01:04:55 +0200 |
| commit | 23a82cba12380b0905670c34395dc460a4bc9984 (patch) | |
| tree | df001ea84a8173dab9381a3ec75d36d25f6a3650 /lisp/emacs-lisp | |
| parent | e712a8fe0929a18eaf3f4ec83b023f475afdc4d4 (diff) | |
| download | emacs-23a82cba12380b0905670c34395dc460a4bc9984.tar.gz | |
Refactoring: have CATCHER_ALL also catch signals.
In all cases where we use a CATCHER_ALL handler we also want to catch
signals. Therefore have 'signal' respect CATCHER_ALL. Adapt internal
interfaces so that handlers can distinguish among the two types of
nonlocal exits in CATCHER_ALL handlers.
* src/lisp.h (enum nonlocal_exit): New enum.
(struct handler): Add member 'nonlocal_exit' to hold the type of
nonlocal exit during stack unwinding.
* src/eval.c (signal_or_quit): Also respect CATCHER_ALL handlers.
(unwind_to_catch): Store nonlocal exit type in catch structure.
(Fthrow, signal_or_quit): Adapt callers.
(internal_catch_all): Install only one handler. Give handler a
nonlocal exit type argument.
(internal_catch_all_1): Remove, no longer needed.
* src/emacs-module.c (MODULE_SETJMP): Install only one handler.
(module_handle_nonlocal_exit): New function to handle all nonlocal
exits.
(MODULE_SETJMP_1): Pass nonlocal exit type to handler function.
(module_handle_signal, module_handle_throw): Remove, no longer needed.
* src/json.c (json_handle_nonlocal_exit): New helper function.
(json_insert_callback): Adapt to change in 'internal_catch_all'.
Diffstat (limited to 'lisp/emacs-lisp')
0 files changed, 0 insertions, 0 deletions
