aboutsummaryrefslogtreecommitdiff
path: root/bfd
diff options
context:
space:
mode:
authorNick Clifton <nickc@redhat.com>2020-08-29 08:03:15 +0100
committerNick Clifton <nickc@redhat.com>2020-08-29 08:03:15 +0100
commite6f04d55f681149a69102a73937d0987719c3f16 (patch)
treee824a883d26c9beb024713503c43a1166555fbdb /bfd
parent55b8e31a7a109bbd4efd7a59408c3c59dcf62ee0 (diff)
downloadgdb-e6f04d55f681149a69102a73937d0987719c3f16.zip
gdb-e6f04d55f681149a69102a73937d0987719c3f16.tar.gz
gdb-e6f04d55f681149a69102a73937d0987719c3f16.tar.bz2
Include members in the variable table used when resolving DW_AT_specification tags.
PR 26520 * dwarf2.c (scan_unit_for_symbols): Add member entries to the variable table.
Diffstat (limited to 'bfd')
-rw-r--r--bfd/ChangeLog6
-rw-r--r--bfd/dwarf2.c5
2 files changed, 9 insertions, 2 deletions
diff --git a/bfd/ChangeLog b/bfd/ChangeLog
index bb817a0..f3d204e 100644
--- a/bfd/ChangeLog
+++ b/bfd/ChangeLog
@@ -1,3 +1,9 @@
+2020-08-29 Nick Clifton <nickc@redhat.com>
+
+ PR 26520
+ * dwarf2.c (scan_unit_for_symbols): Add member entries to the
+ variable table.
+
2020-08-29 Alan Modra <amodra@gmail.com>
PR 26459
diff --git a/bfd/dwarf2.c b/bfd/dwarf2.c
index b8f0008..977bf43 100644
--- a/bfd/dwarf2.c
+++ b/bfd/dwarf2.c
@@ -3404,7 +3404,8 @@ scan_unit_for_symbols (struct comp_unit *unit)
else
{
func = NULL;
- if (abbrev->tag == DW_TAG_variable)
+ if (abbrev->tag == DW_TAG_variable
+ || abbrev->tag == DW_TAG_member)
{
size_t amt = sizeof (struct varinfo);
var = (struct varinfo *) bfd_zalloc (abfd, amt);
@@ -3516,7 +3517,7 @@ scan_unit_for_symbols (struct comp_unit *unit)
spec_var = lookup_var_by_offset (attr.u.val,
unit->variable_table);
if (spec_var == NULL)
- {
+ {
_bfd_error_handler (_("DWARF error: could not find "
"variable specification "
"at offset %lx"),