Unbreak test

llvm-svn: 128168
This commit is contained in:
Douglas Gregor 2011-03-23 21:19:43 +00:00
parent 74af4bc134
commit 336a15e041
2 changed files with 13 additions and 6 deletions

View File

@ -2,11 +2,17 @@
// PR9463
double *end;
void f() {
void f(bool b1, bool b2) {
{
int end = 0;
goto end;
end = 1;
do {
int end = 0;
if (b2) {
do {
goto end;
} while (b2);
}
end = 1;
} while (b1);
}
end:

View File

@ -27,7 +27,8 @@ void f3(S3* p, void (S3::*m)()) {
(void)(void*)(p->*m); // expected-error {{a bound member function may only be called}}
(void)reinterpret_cast<void*>(p->*m); // expected-error {{a bound member function may only be called}}
if (p->*m) {} // expected-error {{a bound member function may only be called}}
if (!p->*m) {} // expected-error {{a bound member function may only be called}}
if (!p->*m) {} // FIXME: xpected-error {{a bound member function may only be called}} \
// expected-error{{left hand operand to ->* must be a pointer to class compatible with the right hand operand, but is 'bool'}}
if (p->m) {}; // expected-error {{a bound member function may only be called}}
if (!p->m) {}; // expected-error {{a bound member function may only be called}}
if (!p->m) {}; // FIXME: xpected-error {{a bound member function may only be called}}
}