From 9394def075d80f60be923ef5b76cdaa006b0bf35 Mon Sep 17 00:00:00 2001 From: Daniel Jacobowitz Date: Sat, 21 Feb 2004 21:08:33 +0000 Subject: * dwarf2read.c (load_partial_dies): Follow unions. Follow aggregates for all non-C languages. --- gdb/ChangeLog.intercu | 5 +++++ gdb/dwarf2read.c | 13 +++++++------ 2 files changed, 12 insertions(+), 6 deletions(-) diff --git a/gdb/ChangeLog.intercu b/gdb/ChangeLog.intercu index 087fe18a416..090af73f276 100644 --- a/gdb/ChangeLog.intercu +++ b/gdb/ChangeLog.intercu @@ -1,3 +1,8 @@ +2004-02-21 Daniel Jacobowitz + + * dwarf2read.c (load_partial_dies): Follow unions. Follow + aggregates for all non-C languages. + 2004-02-21 Daniel Jacobowitz * dwarf2read.c (dwarf2_build_psymtabs_hard): Estimate the initial diff --git a/gdb/dwarf2read.c b/gdb/dwarf2read.c index e7749733053..084392895e4 100644 --- a/gdb/dwarf2read.c +++ b/gdb/dwarf2read.c @@ -4599,16 +4599,17 @@ load_partial_dies (bfd *abfd, char *info_ptr, struct dwarf2_cu *cu) part_die = obstack_alloc (&cu->partial_die_obstack, sizeof (struct partial_die_info)); - /* For some DIEs we want to follow their children (if any). We do - not normally follow the children of structures; do so for C++ - so that we can use method physnames to infer fully qualified - type names. */ + /* For some DIEs we want to follow their children (if any). For C + we have no reason to follow the children of structures; for other + languages we have to, both so that we can get at method physnames + to infer fully qualified class names, and for DW_AT_specification. */ if (last_die->has_children && (last_die->tag == DW_TAG_namespace || last_die->tag == DW_TAG_enumeration_type - || (cu->language == language_cplus + || (cu->language != language_c && (last_die->tag == DW_TAG_class_type - || last_die->tag == DW_TAG_structure_type)))) + || last_die->tag == DW_TAG_structure_type + || last_die->tag == DW_TAG_union_type)))) { nesting_level++; parent_die = last_die; -- cgit v1.2.1