diff options
author | Jim Kingdon <jkingdon@engr.sgi.com> | 1993-07-02 02:57:06 +0000 |
---|---|---|
committer | Jim Kingdon <jkingdon@engr.sgi.com> | 1993-07-02 02:57:06 +0000 |
commit | b2bebdb0f184e8c09c59f9efdc06aea8514939de (patch) | |
tree | 075d0faa680db3c62870055415066b9270070c89 /gdb/dwarfread.c | |
parent | 3fe11d4734efac588b647e4458f22453f3359fbc (diff) | |
download | gdb-b2bebdb0f184e8c09c59f9efdc06aea8514939de.zip gdb-b2bebdb0f184e8c09c59f9efdc06aea8514939de.tar.gz gdb-b2bebdb0f184e8c09c59f9efdc06aea8514939de.tar.bz2 |
* gdbtypes.h (struct type): Add field tag_name.
* gdbtypes.c (type_name_no_tag), c-typeprint.c (c_type_print_base):
Use it.
* {coff,dwarf,mips,stabs}read.c: Set it.
Diffstat (limited to 'gdb/dwarfread.c')
-rw-r--r-- | gdb/dwarfread.c | 13 |
1 files changed, 4 insertions, 9 deletions
diff --git a/gdb/dwarfread.c b/gdb/dwarfread.c index 1e7a6d0..709b958 100644 --- a/gdb/dwarfread.c +++ b/gdb/dwarfread.c @@ -1026,7 +1026,6 @@ struct_type (dip, thisdie, enddie, objfile) struct nextfield *new; int nfields = 0; int n; - char *tpart1; struct dieinfo mbr; char *nextdie; #if !BITS_BIG_ENDIAN @@ -1043,20 +1042,16 @@ struct_type (dip, thisdie, enddie, objfile) { case TAG_class_type: TYPE_CODE (type) = TYPE_CODE_CLASS; - tpart1 = "class"; break; case TAG_structure_type: TYPE_CODE (type) = TYPE_CODE_STRUCT; - tpart1 = "struct"; break; case TAG_union_type: TYPE_CODE (type) = TYPE_CODE_UNION; - tpart1 = "union"; break; default: /* Should never happen */ TYPE_CODE (type) = TYPE_CODE_UNDEF; - tpart1 = "???"; complain (&missing_tag, DIE_ID, DIE_NAME); break; } @@ -1067,8 +1062,8 @@ struct_type (dip, thisdie, enddie, objfile) && *dip -> at_name != '~' && *dip -> at_name != '.') { - TYPE_NAME (type) = obconcat (&objfile -> type_obstack, - tpart1, " ", dip -> at_name); + TYPE_TAG_NAME (type) = obconcat (&objfile -> type_obstack, + "", "", dip -> at_name); } /* Use whatever size is known. Zero is a valid size. We might however wish to check has_at_byte_size to make sure that some byte size was @@ -1756,8 +1751,8 @@ enum_type (dip, objfile) && *dip -> at_name != '~' && *dip -> at_name != '.') { - TYPE_NAME (type) = obconcat (&objfile -> type_obstack, "enum", - " ", dip -> at_name); + TYPE_TAG_NAME (type) = obconcat (&objfile -> type_obstack, + "", "", dip -> at_name); } if (dip -> at_byte_size != 0) { |