Debian Codegraph @

gcc/testsuite/c-c++-common/cpp/Wtrailing-whitespace-1.c

raw
1 /* { dg-do compile { target { c || c++11 } } } */
2 /* { dg-options "-Wtrailing-whitespace" } */
3
4 int i;
5 /* { dg-warning "trailing whitespace" "" { target *-*-* } .-1 } */
6 int j;
7 /* { dg-warning "trailing whitespace" "" { target *-*-* } .-1 } */
8 int \
9 k \
10 ;
11 /* { dg-warning "backslash and newline separated by space" "" { target *-*-* } .-3 } */
12 /* { dg-warning "backslash and newline separated by space" "" { target *-*-* } .-3 } */
13 /* { dg-warning "trailing whitespace" "" { target *-*-* } .-3 } */
14
15
16
17 /* { dg-warning "trailing whitespace" "" { target *-*-* } .-1 } */
18
19
20
21 /* { dg-warning "trailing whitespace" "" { target *-*-* } .-1 } */
22 const char *p = R"*|*(
23
24
25 .
26 )*|*";
27 /* { dg-warning "trailing whitespace" "" { target *-*-* } .-1 } */
28 // This is a comment with trailing whitespace
29 /* { dg-warning "trailing whitespace" "" { target *-*-* } .-1 } */
30 /* This is a comment with trailing whitespace
31 */
32 /* { dg-warning "trailing whitespace" "" { target *-*-* } .-2 } */
33 // This is a comment with trailing whitespace
34 /* This is a comment with trailing whitespace
35 */
36 /* { dg-warning "trailing whitespace" "" { target *-*-* } .+1 } */
37