blob: ffdd71c13afd85ce72485aac1c4fdf4468e23389 [file] [log] [blame]
// { dg-do run }
struct A {
virtual A* f () { return this; }
};
struct B: public A {
virtual B* f () { return 0; }
};
int main ()
{
A* ap = new B;
return (ap->f () != 0);
}