1 | // RUN: %clang_cc1 -fsyntax-only -verify %s |
2 | // RUN: cp %s %t.cpp |
3 | // RUN: not %clang_cc1 -fsyntax-only %t.cpp -fixit |
4 | // RUN: %clang_cc1 -fsyntax-only %t.cpp |
5 | |
6 | void test1(int a;) { // expected-error{{unexpected ';' before ')'}} |
7 | while (a > 5;) {} // expected-error{{unexpected ';' before ')'}} |
8 | for (int c = 0; c < 21; ++c;) {} // expected-error{{unexpected ';' before ')'}} |
9 | int d = int(3 + 4;); // expected-error{{unexpected ';' before ')'}} |
10 | int e[5;]; // expected-error{{unexpected ';' before ']'}} |
11 | e[a+1;] = 4; // expected-error{{unexpected ';' before ']'}} |
12 | int f[] = {1,2,3;}; // expected-error{{unexpected ';' before '}'}} |
13 | } |
14 | |