PR c/47043
[official-gcc.git] / gcc / testsuite / c-c++-common / cpp / diagnostic-pragma-1.c
blob9867c94a8ddc3683d420146b42c88ca8da923b31
1 // { dg-do compile }
3 #pragma GCC warning "warn-a" // { dg-warning warn-a }
4 #pragma GCC error "err-b" // { dg-error err-b }
6 #define CONST1 _Pragma("GCC warning \"warn-c\"") 1
7 #define CONST2 _Pragma("GCC error \"err-d\"") 2
9 char a[CONST1]; // { dg-warning warn-c }
10 char b[CONST2]; // { dg-error err-d }