diff options
author | Kaveh R. Ghazi <ghazi@caip.rutgers.edu> | 2003-05-21 01:39:38 +0000 |
---|---|---|
committer | Kaveh Ghazi <ghazi@gcc.gnu.org> | 2003-05-21 01:39:38 +0000 |
commit | 58228df67b7336300a3c7ceaa3b374e43ab375b9 (patch) | |
tree | ed852382656f4ad935c8848efb21c132d734f28d /gcc/cp | |
parent | bc6688b40ef6cc12e88a2498f82dbb2cd52ee443 (diff) | |
download | gcc-58228df67b7336300a3c7ceaa3b374e43ab375b9.zip gcc-58228df67b7336300a3c7ceaa3b374e43ab375b9.tar.gz gcc-58228df67b7336300a3c7ceaa3b374e43ab375b9.tar.bz2 |
c-pretty-print.c (pp_c_integer_literal): Use HOST_WIDE_INT_PRINT_DOUBLE_HEX.
gcc:
* c-pretty-print.c (pp_c_integer_literal): Use
HOST_WIDE_INT_PRINT_DOUBLE_HEX.
cp:
* error.c (dump_expr): Use HOST_WIDE_INT_PRINT_DOUBLE_HEX.
From-SVN: r67055
Diffstat (limited to 'gcc/cp')
-rw-r--r-- | gcc/cp/ChangeLog | 4 | ||||
-rw-r--r-- | gcc/cp/error.c | 13 |
2 files changed, 7 insertions, 10 deletions
diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog index 7ea230f..270103b 100644 --- a/gcc/cp/ChangeLog +++ b/gcc/cp/ChangeLog @@ -1,3 +1,7 @@ +2003-05-20 Kaveh R. Ghazi <ghazi@caip.rutgers.edu> + + * error.c (dump_expr): Use HOST_WIDE_INT_PRINT_DOUBLE_HEX. + 2003-05-21 Danny Smith <dannysmith@users.sourceforge.net> PR c++/9738 diff --git a/gcc/cp/error.c b/gcc/cp/error.c index 21a87d8..cb7c44f 100644 --- a/gcc/cp/error.c +++ b/gcc/cp/error.c @@ -1471,16 +1471,9 @@ dump_expr (tree t, int flags) ~TREE_INT_CST_HIGH (val) + !TREE_INT_CST_LOW (val)); } - /* Would "%x%0*x" or "%x%*0x" get zero-padding on all - systems? */ - { - static char format[12]; /* "0x%x%09999x\0" */ - if (!format[0]) - sprintf (format, "0x%%x%%0%dx", HOST_BITS_PER_INT / 4); - sprintf (digit_buffer, format, TREE_INT_CST_HIGH (val), - TREE_INT_CST_LOW (val)); - output_add_string (scratch_buffer, digit_buffer); - } + sprintf (digit_buffer, HOST_WIDE_INT_PRINT_DOUBLE_HEX, + TREE_INT_CST_HIGH (val), TREE_INT_CST_LOW (val)); + output_add_string (scratch_buffer, digit_buffer); } else print_integer (scratch_buffer, TREE_INT_CST_LOW (t)); |