opnsense-src/test/Parser/cxx-condition.cpp

12 lines
251 B
C++
Raw Normal View History

2010-01-01 05:34:51 -05:00
// RUN: %clang_cc1 -parse-noop -verify %s
2009-06-02 13:58:47 -04:00
void f() {
int a;
while (a) ;
while (int x) ; // expected-error {{expected '=' after declarator}}
while (float x = 0) ;
if (const int x = a) ;
switch (int x = a+10) {}
for (; int x = ++a; ) ;
}