diff options
Diffstat (limited to 'gcc/testsuite/gcc.dg/cpp-tradwarn1.c')
-rw-r--r-- | gcc/testsuite/gcc.dg/cpp-tradwarn1.c | 30 |
1 files changed, 15 insertions, 15 deletions
diff --git a/gcc/testsuite/gcc.dg/cpp-tradwarn1.c b/gcc/testsuite/gcc.dg/cpp-tradwarn1.c index 8395c80..9085ea6 100644 --- a/gcc/testsuite/gcc.dg/cpp-tradwarn1.c +++ b/gcc/testsuite/gcc.dg/cpp-tradwarn1.c @@ -2,27 +2,27 @@ /* { dg-do preprocess } */ /* { dg-options "-pedantic -Wtraditional" } */ -/* Block 1: K+R directives should have the # at the left margin. */ +/* Block 1: K+R directives should have the # indented. */ -#define foo bar /* { dg-bogus "left margin" "^#kandr" } */ -# define foo bar /* { dg-bogus "left margin" "^# kandr" } */ - #define foo bar /* { dg-warning "left margin" "^ #kandr" } */ - # define foo bar /* { dg-warning "left margin" "^ # kandr" } */ +#define foo bar /* { dg-bogus "indented" "^#kandr" } */ +# define foo bar /* { dg-bogus "indented" "^# kandr" } */ + #define foo bar /* { dg-warning "indented" "^ #kandr" } */ + # define foo bar /* { dg-warning "indented" "^ # kandr" } */ -/* Block 2: C89 directives should not have the # at the left margin. */ +/* Block 2: C89 directives should not have the # indented. */ -#pragma whatever /* { dg-warning "left margin" "^#c89" } */ -# pragma whatever /* { dg-warning "left margin" "^# c89" } */ - #pragma whatever /* { dg-bogus "left margin" "^ #c89" } */ - # pragma whatever /* { dg-bogus "left margin" "^ # c89" } */ +#pragma whatever /* { dg-warning "indented" "^#c89" } */ +# pragma whatever /* { dg-warning "indented" "^# c89" } */ + #pragma whatever /* { dg-bogus "indented" "^ #c89" } */ + # pragma whatever /* { dg-bogus "indented" "^ # c89" } */ -/* Block 3: Extensions should not have the # at the left margin, +/* Block 3: Extensions should not have the # indented, _and_ they should get a -pedantic warning. */ -#assert foo(bar) /* { dg-warning "left margin" "^#ext" } */ -# assert bar(baz) /* { dg-warning "left margin" "^# ext" } */ - #assert baz(quux) /* { dg-bogus "left margin" "^ #ext" } */ - # assert quux(weeble) /* { dg-bogus "left margin" "^ # ext" } */ +#assert foo(bar) /* { dg-warning "indented" "^#ext" } */ +# assert bar(baz) /* { dg-warning "indented" "^# ext" } */ + #assert baz(quux) /* { dg-bogus "indented" "^ #ext" } */ + # assert quux(weeble) /* { dg-bogus "indented" "^ # ext" } */ /* { dg-warning "ISO C does not" "extension warning" { target native } 22 } */ /* { dg-warning "ISO C does not" "extension warning" { target native } 23 } */ |