aboutsummaryrefslogtreecommitdiff
path: root/gdb/main.c
diff options
context:
space:
mode:
authorTom Tromey <tom@tromey.com>2019-01-24 09:56:49 -0700
committerTom Tromey <tom@tromey.com>2019-03-06 16:04:31 -0700
commitfe7b42e5843ef82f97959e0e18122c164449a8ea (patch)
tree9324d78cdb2e523c04fc6556882c21280606132f /gdb/main.c
parentc6321f19c5414c2a34db3cf5979834d081c32abd (diff)
downloadgdb-fe7b42e5843ef82f97959e0e18122c164449a8ea.zip
gdb-fe7b42e5843ef82f97959e0e18122c164449a8ea.tar.gz
gdb-fe7b42e5843ef82f97959e0e18122c164449a8ea.tar.bz2
Remove basic cleanup code
This removes the basic cleanup code: make_cleanups, do_cleanups, discard_cleanups, and friends. This code is no longer needed, as nothing in gdb makes an ordinary cleanup. Final cleanups are still needed. 2019-03-06 Tom Tromey <tom@tromey.com> * top.c (quit_force): Update. * main.c (captured_command_loop): Update. * common/new-op.c (operator new): Update. * common/common-exceptions.c (struct catcher) <save_cleanup_chain>: Remove member. (exceptions_state_mc_init): Update. (exception_try_scope_entry): Return nullptr. (exception_try_scope_exit, exception_rethrow) (throw_exception_sjlj, throw_exception_cxx): Update. * common/cleanups.h (make_cleanup, make_cleanup_dtor) (all_cleanups, do_cleanups, discard_cleanups) (discard_final_cleanups, save_cleanups, save_final_cleanups) (restore_cleanups, restore_final_cleanups): Don't declare. (do_final_cleanups): Remove parameter. * common/cleanups.c (cleanup_chain, make_cleanup) (make_cleanup_dtor, all_cleanups, do_cleanups) (discard_my_cleanups, discard_cleanups) (discard_final_cleanups, save_my_cleanups, save_cleanups) (save_final_cleanups, restore_my_cleanups, restore_cleanups) (null_cleanup): Remove. (do_final_cleanups): Remove parameter.
Diffstat (limited to 'gdb/main.c')
-rw-r--r--gdb/main.c8
1 files changed, 0 insertions, 8 deletions
diff --git a/gdb/main.c b/gdb/main.c
index e14dd06..97ffc3f 100644
--- a/gdb/main.c
+++ b/gdb/main.c
@@ -330,14 +330,6 @@ captured_command_loop ()
/* Now it's time to start the event loop. */
start_event_loop ();
- /* FIXME: cagney/1999-11-05: A correct command_loop() implementaton
- would clean things up (restoring the cleanup chain) to the state
- they were just prior to the call. Technically, this means that
- the do_cleanups() below is redundant. Unfortunately, many FUNCs
- are not that well behaved. do_cleanups should either be replaced
- with a do_cleanups call (to cover the problem) or an assertion
- check to detect bad FUNCs code. */
- do_cleanups (all_cleanups ());
/* If the command_loop returned, normally (rather than threw an
error) we try to quit. If the quit is aborted, our caller
catches the signal and restarts the command loop. */