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]

[PING][Patch, Testsuite] fix failure in test gcc.dg/pr52283.c


PING! Here is the original post:
http://gcc.gnu.org/ml/gcc-patches/2012-04/msg01235.html

This patch fixes the failure in gcc.dg/pr52283.c by adding the missing
dg-warning and dg-options.

OK for trunk?

Thanks,
Greta

gcc/testsuite/ChangeLog

2012-04-20  Greta Yorsh  <Greta.Yorsh@arm.com>

	* gcc.dg/pr52283.c: Add missing dg-warning and dg-options.


diff --git a/gcc/testsuite/gcc.dg/pr52283.c b/gcc/testsuite/gcc.dg/pr52283.c
index 33785a5..070e71a 100644
--- a/gcc/testsuite/gcc.dg/pr52283.c
+++ b/gcc/testsuite/gcc.dg/pr52283.c
@@ -1,6 +1,7 @@
 /* Test for case labels not integer constant expressions but folding
    to integer constants (used in Linux kernel).  */
 /* { dg-do compile } */
+/* { dg-options "-pedantic" } */
 
 extern unsigned int u;
 
@@ -9,7 +10,7 @@ b (int c)
 {
   switch (c)
     {
-    case (int) (2  | ((4 < 8) ? 8 : u)):
+    case (int) (2  | ((4 < 8) ? 8 : u)): /* { dg-warning "case label is not
an integer constant expression" } */
       ;
     }
 }




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