Chris Lattner | 1500881 | 2006-06-18 07:00:07 +0000 | [diff] [blame] | 1 | /* |
Bill Wendling | fdddfc1 | 2007-06-27 07:26:41 +0000 | [diff] [blame^] | 2 | RUN: clang -E %s | grep bar && |
| 3 | RUN: clang -E %s | grep foo && |
| 4 | RUN: clang -E %s | not grep abc && |
| 5 | RUN: clang -E %s | not grep xyz && |
Bill Wendling | ff1d2c8 | 2007-06-27 04:07:44 +0000 | [diff] [blame] | 6 | RUN: clang -parse-ast-check %s |
| 7 | */ |
Chris Lattner | 1500881 | 2006-06-18 07:00:07 +0000 | [diff] [blame] | 8 | |
| 9 | /* abc |
| 10 | |
| 11 | ends with normal escaped newline: |
| 12 | *\ |
Bill Wendling | ff1d2c8 | 2007-06-27 04:07:44 +0000 | [diff] [blame] | 13 | / \ |
| 14 | /* expected-warning {{escaped newline between}} \ |
| 15 | expected-warning {{backslash and newline separated by space}} */ |
Chris Lattner | 1500881 | 2006-06-18 07:00:07 +0000 | [diff] [blame] | 16 | |
| 17 | bar |
| 18 | |
| 19 | /* xyz |
| 20 | |
| 21 | |
| 22 | ends with a trigraph escaped newline: |
| 23 | *??/ |
Bill Wendling | ff1d2c8 | 2007-06-27 04:07:44 +0000 | [diff] [blame] | 24 | / \ |
| 25 | /* expected-warning {{escaped newline between}} \ |
| 26 | expected-warning {{backslash and newline separated by space}} \ |
| 27 | expected-warning {{trigraph ends block comment}} */ |
Chris Lattner | 1500881 | 2006-06-18 07:00:07 +0000 | [diff] [blame] | 28 | |
Bill Wendling | ff1d2c8 | 2007-06-27 04:07:44 +0000 | [diff] [blame] | 29 | foo \ |
| 30 | /* expected-error \ |
| 31 | {{expected '=', ',', ';', 'asm', or '__attribute__' after declarator}} */ |
Chris Lattner | 1500881 | 2006-06-18 07:00:07 +0000 | [diff] [blame] | 32 | |