]> granicus.if.org Git - clang/commitdiff
Cut down a few of the excess errors in the test.
authorArgyrios Kyrtzidis <akyrtzi@gmail.com>
Tue, 28 Jun 2011 03:01:09 +0000 (03:01 +0000)
committerArgyrios Kyrtzidis <akyrtzi@gmail.com>
Tue, 28 Jun 2011 03:01:09 +0000 (03:01 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@133983 91177308-0d34-0410-b5e6-96231b3b80d8

test/SemaCXX/condition.cpp

index 61d1762be85f241379822cb933aaa8ae24fa51c7..cb7391a5f1f74f43aa6f9470ed256cdaafac66a9 100644 (file)
@@ -16,8 +16,8 @@ void test() {
   for (;s;) ; // expected-error {{value of type 'struct S' is not contextually convertible to 'bool'}}
   switch (s) {} // expected-error {{statement requires expression of integer type ('struct S' invalid)}}
 
-  while (struct S {} x=0) ; // expected-error {{types may not be defined in conditions}} expected-error {{no viable conversion}} expected-error {{value of type 'struct S' is not contextually convertible to 'bool'}} expected-note{{candidate constructor (the implicit copy constructor)}}
-  while (struct {} x=0) ; // expected-error {{types may not be defined in conditions}} expected-error {{no viable conversion}} expected-error {{not contextually convertible to 'bool'}} expected-note{{candidate constructor (the implicit copy constructor)}}
+  while (struct S {} *x=0) ; // expected-error {{types may not be defined in conditions}}
+  while (struct {} *x=0) ; // expected-error {{types may not be defined in conditions}}
   switch (enum {E} x=0) ; // expected-error {{types may not be defined in conditions}} expected-error {{cannot initialize}} \
   // expected-warning{{enumeration value 'E' not handled in switch}}