Remove ALL_OBJFILES_SAFE
authorTom Tromey <tom@tromey.com>
Sat, 24 Nov 2018 00:09:34 +0000 (17:09 -0700)
committerTom Tromey <tom@tromey.com>
Thu, 10 Jan 2019 01:28:14 +0000 (18:28 -0700)
commitcac85af2467c9bac326b397b150274d95d2916a5
tree1e9c3722cd2e1592218f8dc5c7e31a154d848a3e
parentaed57c537116ae91f553ac835b3f96d1f87b3bb0
Remove ALL_OBJFILES_SAFE

This removes the ALL_OBJFILES_SAFE macro, replacing the uses with
ranged for loops.

gdb/ChangeLog
2019-01-09  Tom Tromey  <tom@tromey.com>

* common/next-iterator.h (next_adapter): Add Iterator template
parameter.
* objfiles.h (ALL_OBJFILES_SAFE): Remove.
(class all_objfiles_safe): New.
* jit.c (jit_inferior_exit_hook): Use all_objfiles_safe.
* objfiles.c (put_objfile_before): Update comment.
(add_separate_debug_objfile): Likewise.
(free_all_objfiles): Use all_objfiles_safe.
(objfile_purge_solibs): Likewise.
gdb/ChangeLog
gdb/common/next-iterator.h
gdb/jit.c
gdb/objfiles.c
gdb/objfiles.h