]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commit
Consolidate partial symtab dependency reading
authorTom Tromey <tom@tromey.com>
Wed, 23 Oct 2019 15:46:25 +0000 (09:46 -0600)
committerTom Tromey <tom@tromey.com>
Sun, 26 Jan 2020 23:40:21 +0000 (16:40 -0700)
commit0494dbecdfa0b0b9065393755a1ac64431997da1
tree62a9775a68571e89257e1ac2b0d1a88ac55526c0
parent8566b89b737eef50f67bf23329b4606cf7973de1
Consolidate partial symtab dependency reading

Most of the symbol readers have code to iterate over a partial symtabs
dependencies, expanding each one and optionally printing a message.
Now that the "second-stage" psymtab expansion is available as a
method, these implementations can all be merged.

This patch also changes a couple more warnings into assertions.

gdb/ChangeLog
2020-01-26  Tom Tromey  <tom@tromey.com>

* xcoffread.c (xcoff_psymtab_to_symtab_1): Call
read_dependencies.  Add assert.
* psymtab.c (partial_symtab::read_dependencies): New method.
* psympriv.h (struct partial_symtab) <read_dependencies>: New
method.
* mdebugread.c (psymtab_to_symtab_1): Call read_dependencies.
* dwarf2read.c (dwarf2_psymtab::expand_psymtab): Call
read_dependencies.
* dbxread.c (dbx_psymtab_to_symtab_1): Call read_dependencies.
Add assert.

Change-Id: I8151e05677794e90223edc1a4cb70f7f69137d46
gdb/ChangeLog
gdb/dbxread.c
gdb/dwarf2read.c
gdb/mdebugread.c
gdb/psympriv.h
gdb/psymtab.c
gdb/xcoffread.c