aboutsummaryrefslogtreecommitdiff
path: root/gcc/dbxout.c
diff options
context:
space:
mode:
authorRichard Stallman <rms@gnu.org>1993-09-07 12:27:26 +0000
committerRichard Stallman <rms@gnu.org>1993-09-07 12:27:26 +0000
commit71f1501370b2873a7f4615bbc67c4b421f285986 (patch)
tree64d9930f5ab35ecde7c9283a340aa9838dda5b20 /gcc/dbxout.c
parent86463d5d64e4331c4ae0aece37950a5c445d0945 (diff)
downloadgcc-71f1501370b2873a7f4615bbc67c4b421f285986.zip
gcc-71f1501370b2873a7f4615bbc67c4b421f285986.tar.gz
gcc-71f1501370b2873a7f4615bbc67c4b421f285986.tar.bz2
(dbxout_type): Handle enum constants bigger than one word.
Don't print big unsigned values as negative. From-SVN: r5273
Diffstat (limited to 'gcc/dbxout.c')
-rw-r--r--gcc/dbxout.c15
1 files changed, 12 insertions, 3 deletions
diff --git a/gcc/dbxout.c b/gcc/dbxout.c
index 1bf21af..8e8c08a 100644
--- a/gcc/dbxout.c
+++ b/gcc/dbxout.c
@@ -1244,9 +1244,18 @@ dbxout_type (type, full, show_arg_types)
CHARS (1);
for (tem = TYPE_VALUES (type); tem; tem = TREE_CHAIN (tem))
{
- fprintf (asmfile, "%s:%d,", IDENTIFIER_POINTER (TREE_PURPOSE (tem)),
- TREE_INT_CST_LOW (TREE_VALUE (tem)));
- CHARS (11 + IDENTIFIER_LENGTH (TREE_PURPOSE (tem)));
+ fprintf (asmfile, "%s:", IDENTIFIER_POINTER (TREE_PURPOSE (tem)));
+ if (TREE_INT_CST_HIGH (TREE_VALUE (tem)) == 0)
+ {
+ if (TREE_INT_CST_LOW (TREE_VALUE (tem)) < 0)
+ fprintf (asmfile, "%u", TREE_INT_CST_LOW (TREE_VALUE (tem)));
+ else
+ fprintf (asmfile, "%d", TREE_INT_CST_LOW (TREE_VALUE (tem)));
+ }
+ else
+ print_int_cst_octal (TREE_VALUE (tem));
+ fprintf (asmfile, ",");
+ CHARS (20 + IDENTIFIER_LENGTH (TREE_PURPOSE (tem)));
if (TREE_CHAIN (tem) != 0)
CONTIN;
}