Remove free_cached_comp_units cleanups
authorTom Tromey <tom@tromey.com>
Wed, 28 Mar 2018 21:04:30 +0000 (15:04 -0600)
committerTom Tromey <tom@tromey.com>
Fri, 30 Mar 2018 19:15:57 +0000 (13:15 -0600)
commit11ed8cada64e717900117364c2fee0132c1eb099
treeb3edabc80fab73f447eb4a041fe177e8279430d9
parent9ae79dac31c2bcbd2f5418da2e12af94060e139a
Remove free_cached_comp_units cleanups

This changes free_cached_comp_units from a cleanup function to an RAII
class.

gdb/ChangeLog
2018-03-30  Tom Tromey  <tom@tromey.com>

* dwarf2read.c (class free_cached_comp_units): New class.
(dw2_instantiate_symtab, dwarf2_build_psymtabs_hard): Use it.
(free_cached_comp_units): Remove function.
gdb/ChangeLog
gdb/dwarf2read.c