2003-12-26 Guilhem Lavaux <guilhem@kaffe.org>
[official-gcc.git] / gcc / testsuite / g++.old-deja / g++.mike / warn8.C
blob46818fa713f4b3318525c2003eceda2b9d1967ad
1 // { dg-do assemble  }
3 struct foo {
4   bool test();
5 };
6 bool func();
8 void test() {
9   foo A;
10   bool (foo::* pmf)() = &foo::test;
11   bool (*pf)() = func;
13   if (A.test) ;                 // { dg-error "" } 
14   if (func) ;                   // { dg-warning "" } 
15   if (bool(A.test)) ;           // { dg-error "" } 
16   if (bool(func)) ;             // { dg-warning "" } 
17   if (pmf) ;
18   if (pf) ;