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]

[testsuite] fix two test-framework tests


The warning "return type defaults to 'int' moved a few months ago from
the opening brace in a function to the line with the function name.
This broke two tests for the test framework.  This patch fixes those
tests of dg-bogus and dg-warning functionality by joining the two lines.
Checked in on trunk.

2009-09-29  Janis Johnson  <janis187@us.ibm.com>

	* gcc.test-framework/dg-bogus-exp-XF.c: Move dg-bogus directive.
	* gcc.test-framework/dg-warning-exp-P.c: Move dg-warning directives.

Index: gcc/testsuite/gcc.test-framework/dg-bogus-exp-XF.c
===================================================================
--- gcc/testsuite/gcc.test-framework/dg-bogus-exp-XF.c	(revision 152255)
+++ gcc/testsuite/gcc.test-framework/dg-bogus-exp-XF.c	(working copy)
@@ -2,8 +2,7 @@
 /* { dg-prms-id 42 } */
 /* { dg-options "-Wall" } */
 
-main (int argc, char *argv[])
-{	/* { dg-bogus "return type" "bogus pass test" { xfail *-*-* } } */
+main (int argc, char *argv[]) {	/* { dg-bogus "return type" "bogus pass test" { xfail *-*-* } } */
 }
 
 /* { dg-excess-errors "bogus pass test" { xfail *-*-* } } */
Index: gcc/testsuite/gcc.test-framework/dg-warning-exp-P.c
===================================================================
--- gcc/testsuite/gcc.test-framework/dg-warning-exp-P.c	(revision 152255)
+++ gcc/testsuite/gcc.test-framework/dg-warning-exp-P.c	(working copy)
@@ -2,10 +2,8 @@
 /* { dg-prms-id 42 } */
 /* { dg-options "-Wall" } */
 
-f ()
-{	/* { dg-warning "return type" "warning test" } */
+f () {	/* { dg-warning "return type" "warning test" } */
 }	/* { dg-warning "control reaches end" "warning test" } */
 
-main (int argc, char *argv[])
-{		/* { dg-warning "return type" "warning test" } */
-}		/* { dg-warning "control reaches end" "warning test" } */
+main (int argc, char *argv[]) {	/* { dg-warning "return type" "warning test" } */
+}	/* { dg-warning "control reaches end" "warning test" } */



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