Simplify exception handling
authorTom Tromey <tom@tromey.com>
Fri, 25 Jan 2019 00:31:21 +0000 (17:31 -0700)
committerTom Tromey <tom@tromey.com>
Mon, 8 Apr 2019 15:05:37 +0000 (09:05 -0600)
commitc5c10118216867e133c132b4f46e19fb6aa9258a
tree46b80e4714d51d586f4f11ffc0a33df9e695e6d4
parentd970ee2bae1925bb9265d37adef0b92e2678d666
Simplify exception handling

Now that cleanups have been removed, TRY/CATCH can't be SJLJ-based any
more.  This patch simplifies the exception handling code, by removing
the non-working variants.

Note that the "pure" C++ exception handling code is removed as well; I
think the route forward must be to change exceptions to be
self-destructing, so that try_scope_depth can simply be removed.

Some longjmp-based code remains, as it is needed to throw an exception
through readline.

gdb/ChangeLog
2019-04-08  Tom Tromey  <tom@tromey.com>

* common/common-exceptions.h (GDB_XCPT_SJMP, GDB_XCPT_TRY)
(GDB_XCPT_RAW_TRY, GDB_XCPT): Remove.
(TRY, CATCH, END_CATCH): Remove some definitions.
* common/common-exceptions.c: Don't use GDB_XCPT.
(catcher_list_size): Remove.
(throw_exception, throw_it): Simplify.
gdb/ChangeLog
gdb/common/common-exceptions.c
gdb/common/common-exceptions.h