FYI: fix PR 12441
Tom Tromey
tromey@redhat.com
Mon Mar 28 20:19:00 GMT 2011
I'm checking this in.
PR 12441 pointed out that we incorrectly pass language_minimal to
prepare_one_comp_unit; causing CUs without a language to show up as Ada,
since (int) language_minimal == (int) DW_LANG_Ada95.
Fixed as appended.
Built and regtested on x86-64 (compile farm).
Tom
2011-03-28 Tom Tromey <tromey@redhat.com>
PR symtab/12441:
* dwarf2read.c (prepare_one_comp_unit): Don't call set_cu_language
with `language_minimal'.
Index: dwarf2read.c
===================================================================
RCS file: /cvs/src/src/gdb/dwarf2read.c,v
retrieving revision 1.514
diff -u -r1.514 dwarf2read.c
--- dwarf2read.c 24 Mar 2011 20:35:08 -0000 1.514
+++ dwarf2read.c 28 Mar 2011 19:48:33 -0000
@@ -14679,7 +14679,10 @@
if (attr)
set_cu_language (DW_UNSND (attr), cu);
else
- set_cu_language (language_minimal, cu);
+ {
+ cu->language = language_minimal;
+ cu->language_defn = language_def (cu->language);
+ }
}
/* Release one cached compilation unit, CU. We unlink it from the tree
More information about the Gdb-patches
mailing list