diff options
Diffstat (limited to 'gcc/cp')
-rw-r--r-- | gcc/cp/ChangeLog | 7 | ||||
-rw-r--r-- | gcc/cp/ptree.c | 20 | ||||
-rw-r--r-- | gcc/cp/tree.c | 7 |
3 files changed, 18 insertions, 16 deletions
diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog index 403c7fe..217d447 100644 --- a/gcc/cp/ChangeLog +++ b/gcc/cp/ChangeLog @@ -1,3 +1,10 @@ +2003-05-16 Kaveh R. Ghazi <ghazi@caip.rutgers.edu> + + * ptree.c (cxx_print_type, cxx_print_xnode): Use string + concatentation on HOST_WIDE_INT_PRINT_* format specifier to + collapse multiple function calls into one. + * tree.c (debug_binfo): Likewise. + 2003-05-15 Jason Merrill <jason@redhat.com> PR c++/5388 diff --git a/gcc/cp/ptree.c b/gcc/cp/ptree.c index aefc961..900e8b0 100644 --- a/gcc/cp/ptree.c +++ b/gcc/cp/ptree.c @@ -73,12 +73,10 @@ cxx_print_type (FILE *file, tree node, int indent) case TEMPLATE_TEMPLATE_PARM: case BOUND_TEMPLATE_TEMPLATE_PARM: indent_to (file, indent + 3); - fputs ("index ", file); - fprintf (file, HOST_WIDE_INT_PRINT_DEC, TEMPLATE_TYPE_IDX (node)); - fputs (" level ", file); - fprintf (file, HOST_WIDE_INT_PRINT_DEC, TEMPLATE_TYPE_LEVEL (node)); - fputs (" orig_level ", file); - fprintf (file, HOST_WIDE_INT_PRINT_DEC, TEMPLATE_TYPE_ORIG_LEVEL (node)); + fprintf (file, "index " HOST_WIDE_INT_PRINT_DEC " level " + HOST_WIDE_INT_PRINT_DEC " orig_level " HOST_WIDE_INT_PRINT_DEC, + TEMPLATE_TYPE_IDX (node), TEMPLATE_TYPE_LEVEL (node), + TEMPLATE_TYPE_ORIG_LEVEL (node)); return; case FUNCTION_TYPE: @@ -185,12 +183,10 @@ cxx_print_xnode (FILE *file, tree node, int indent) break; case TEMPLATE_PARM_INDEX: indent_to (file, indent + 3); - fputs ("index ", file); - fprintf (file, HOST_WIDE_INT_PRINT_DEC, TEMPLATE_PARM_IDX (node)); - fputs (" level ", file); - fprintf (file, HOST_WIDE_INT_PRINT_DEC, TEMPLATE_PARM_LEVEL (node)); - fputs (" orig_level ", file); - fprintf (file, HOST_WIDE_INT_PRINT_DEC, TEMPLATE_PARM_ORIG_LEVEL (node)); + fprintf (file, "index " HOST_WIDE_INT_PRINT_DEC " level " + HOST_WIDE_INT_PRINT_DEC " orig_level " HOST_WIDE_INT_PRINT_DEC, + TEMPLATE_PARM_IDX (node), TEMPLATE_PARM_LEVEL (node), + TEMPLATE_PARM_ORIG_LEVEL (node)); break; default: break; diff --git a/gcc/cp/tree.c b/gcc/cp/tree.c index 0566a09..c333612 100644 --- a/gcc/cp/tree.c +++ b/gcc/cp/tree.c @@ -984,11 +984,10 @@ debug_binfo (elem) HOST_WIDE_INT n; tree virtuals; - fprintf (stderr, "type \"%s\", offset = ", - TYPE_NAME_STRING (BINFO_TYPE (elem))); - fprintf (stderr, HOST_WIDE_INT_PRINT_DEC, + fprintf (stderr, "type \"%s\", offset = " HOST_WIDE_INT_PRINT_DEC + "\nvtable type:\n", + TYPE_NAME_STRING (BINFO_TYPE (elem)), TREE_INT_CST_LOW (BINFO_OFFSET (elem))); - fprintf (stderr, "\nvtable type:\n"); debug_tree (BINFO_TYPE (elem)); if (BINFO_VTABLE (elem)) fprintf (stderr, "vtable decl \"%s\"\n", |