diff options
author | Tom Tromey <tom@tromey.com> | 2021-03-20 17:23:40 -0600 |
---|---|---|
committer | Tom Tromey <tom@tromey.com> | 2021-03-20 17:23:42 -0600 |
commit | 484b1090630d273dfb70ee96b152ec6b527a1b65 (patch) | |
tree | 0e0a8a9a6e33be2fb7d4dbca9ca632ef9735cca5 /gdb/dwarf2 | |
parent | 7e9c0476a7085cbebdc818d163d5c3bd46da6388 (diff) | |
download | gdb-484b1090630d273dfb70ee96b152ec6b527a1b65.zip gdb-484b1090630d273dfb70ee96b152ec6b527a1b65.tar.gz gdb-484b1090630d273dfb70ee96b152ec6b527a1b65.tar.bz2 |
Do not pass objfile to psymtab_discarder
This changes the psymtab_discarder to not assume that partial symtabs
are attached to the objfile. Instead, a psymtab_storage object is
passed directly to it.
gdb/ChangeLog
2021-03-20 Tom Tromey <tom@tromey.com>
* psympriv.h (psymtab_discarder): Take psymtab_storage parameter.
(~psymtab_discarder, keep): Update.
<m_objfile>: Remove.
<m_partial_symtabs>: New member.
* dwarf2/read.c (dwarf2_build_psymtabs): Update.
Diffstat (limited to 'gdb/dwarf2')
-rw-r--r-- | gdb/dwarf2/read.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/gdb/dwarf2/read.c b/gdb/dwarf2/read.c index 19e5cdb..aad25f7 100644 --- a/gdb/dwarf2/read.c +++ b/gdb/dwarf2/read.c @@ -6142,7 +6142,7 @@ dwarf2_build_psymtabs (struct objfile *objfile) /* This isn't really ideal: all the data we allocate on the objfile's obstack is still uselessly kept around. However, freeing it seems unsafe. */ - psymtab_discarder psymtabs (objfile); + psymtab_discarder psymtabs (objfile->partial_symtabs.get ()); dwarf2_build_psymtabs_hard (per_objfile); psymtabs.keep (); |