diff options
author | Peter Schauer <Peter.Schauer@mytum.de> | 1995-10-21 13:14:53 +0000 |
---|---|---|
committer | Peter Schauer <Peter.Schauer@mytum.de> | 1995-10-21 13:14:53 +0000 |
commit | 09af58685445072bdf77e9257632da71f979162c (patch) | |
tree | a9eb8ec564ac3f31945f3e767f6887260d134a40 /gdb/dwarfread.c | |
parent | 8490169d216ca66f0d2a2a627d9be8aaadaa9ced (diff) | |
download | gdb-09af58685445072bdf77e9257632da71f979162c.zip gdb-09af58685445072bdf77e9257632da71f979162c.tar.gz gdb-09af58685445072bdf77e9257632da71f979162c.tar.bz2 |
* alpha-tdep.c, mips-tdep.c (init_extra_frame_info):
Do not set saved registers from heuristics for a sigtramp frame.
* dwarfread.c (enum_type): Determine signedness of enum type
from enumerators.
* mips-tdep.c: Include gdb_string.h, gcc -Wall lint.
* rs6000-nat.c (xcoff_relocate_core): Fix typo.
* valops.c (value_repeat): Fix length of memory transfer to
match recent allocate_repeat_value change.
Diffstat (limited to 'gdb/dwarfread.c')
-rw-r--r-- | gdb/dwarfread.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/gdb/dwarfread.c b/gdb/dwarfread.c index bd92ad1..a68cdf1 100644 --- a/gdb/dwarfread.c +++ b/gdb/dwarfread.c @@ -1689,6 +1689,7 @@ enum_type (dip, objfile) unsigned short blocksz; struct symbol *sym; int nbytes; + int unsigned_enum = 1; if ((type = lookup_utype (dip -> die_ref)) == NULL) { @@ -1749,6 +1750,8 @@ enum_type (dip, objfile) SYMBOL_CLASS (sym) = LOC_CONST; SYMBOL_TYPE (sym) = type; SYMBOL_VALUE (sym) = list -> field.bitpos; + if (SYMBOL_VALUE (sym) < 0) + unsigned_enum = 0; add_symbol_to_list (sym, list_in_scope); } /* Now create the vector of fields, and record how big it is. This is @@ -1758,6 +1761,8 @@ enum_type (dip, objfile) vector. */ if (nfields > 0) { + if (unsigned_enum) + TYPE_FLAGS (type) |= TYPE_FLAG_UNSIGNED; TYPE_NFIELDS (type) = nfields; TYPE_FIELDS (type) = (struct field *) obstack_alloc (&objfile->symbol_obstack, sizeof (struct field) * nfields); |