diff options
Diffstat (limited to 'contrib/gcc/dwarf2out.c')
-rw-r--r-- | contrib/gcc/dwarf2out.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/contrib/gcc/dwarf2out.c b/contrib/gcc/dwarf2out.c index e624bc9..75e842c 100644 --- a/contrib/gcc/dwarf2out.c +++ b/contrib/gcc/dwarf2out.c @@ -10383,14 +10383,15 @@ gen_enumeration_type_die (type, context_die) add_name_attribute (enum_die, IDENTIFIER_POINTER (TREE_PURPOSE (link))); - if (host_integerp (TREE_VALUE (link), 0)) + if (host_integerp (TREE_VALUE (link), + TREE_UNSIGNED (TREE_TYPE (TREE_VALUE (link))))) { if (tree_int_cst_sgn (TREE_VALUE (link)) < 0) add_AT_int (enum_die, DW_AT_const_value, tree_low_cst (TREE_VALUE (link), 0)); else add_AT_unsigned (enum_die, DW_AT_const_value, - tree_low_cst (TREE_VALUE (link), 0)); + tree_low_cst (TREE_VALUE (link), 1)); } } } |