This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [tuples] [patch] make gimple-pretty-print closer to tree-pretty-print


On 4/29/08 10:22 AM, Rafael Espindola wrote:
The attached patch reduces the number or arbitrary differences in the
dumps from trunk and tuples.

I typically use something like this on my trunk tree. It may be worth adding this to trunk, but it's not terribly important.



Diego.
Index: tree-pretty-print.c
===================================================================
--- tree-pretty-print.c	(revision 134692)
+++ tree-pretty-print.c	(working copy)
@@ -1653,10 +1653,9 @@ dump_generic_node (pretty_printer *buffe
 		      pp_string (buffer, " goto ");
 		      dump_generic_node (buffer, CASE_LABEL (elt), spc+4,
 					 flags, true);
-		      pp_semicolon (buffer);
 		    }
 		  else
-		    pp_string (buffer, "case ???: goto ???;");
+		    pp_string (buffer, "case ???: goto ???");
 		}
 	    }
 	  newline_and_indent (buffer, spc+2);
@@ -2178,9 +2177,6 @@ dump_generic_node (pretty_printer *buffe
       NIY;
     }
 
-  if (is_stmt && is_expr)
-    pp_semicolon (buffer);
-
   /* If we're building a diagnostic, the formatted text will be written
      into BUFFER's stream by the caller; otherwise, write it now.  */
   if (!(flags & TDF_DIAGNOSTIC))
@@ -2276,8 +2272,6 @@ print_declaration (pretty_printer *buffe
       dump_generic_node (buffer, DECL_VALUE_EXPR (t), spc, flags, false);
       pp_character (buffer, ']');
     }
-
-  pp_character (buffer, ';');
 }
 
 
@@ -3079,7 +3073,6 @@ pp_cfg_jump (pretty_printer *buffer, bas
       dump_generic_node (buffer, LABEL_EXPR_LABEL (stmt), 0, 0, false);
       pp_string (buffer, ")");
     }
-  pp_semicolon (buffer);
 }
 
 /* Dump edges represented implicitly in basic block BB to BUFFER, indented

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]