Chris Lattner | c30ebfb | 2007-08-27 04:29:41 +0000 | [diff] [blame] | 1 | /* RUN: clang %s -std=c89 -pedantic -parse-ast-check |
| 2 | */ |
| 3 | void foo() { |
| 4 | { |
| 5 | int i; |
| 6 | i = i + 1; |
| 7 | int j; /* expected-warning {{mixing declarations and code}} */ |
| 8 | } |
| 9 | { |
| 10 | __extension__ int i; |
| 11 | i = i + 1; |
| 12 | int j; /* expected-warning {{mixing declarations and code}} */ |
| 13 | } |
| 14 | { |
| 15 | int i; |
| 16 | i = i + 1; |
| 17 | __extension__ int j; /* expected-warning {{mixing declarations and code}} */ |
| 18 | } |
| 19 | } |
Chris Lattner | b23deda | 2007-08-28 16:40:32 +0000 | [diff] [blame^] | 20 | |
| 21 | long long x; /* expected-warning {{extension}} */ |
| 22 | |