Fix type in the changelog entry,
[official-gcc.git] / gcc / testsuite / g++.dg / ipa / devirt-39.C
blobbb5ce66f512431eb2e1ada30d88fe13f3dc36c60
1 // PR c++/61214
2 /* { dg-options "-O2 -fdump-tree-optimized"  } */
4 struct Base
6   virtual ~Base();
7   virtual Base* clone() {
8     return 0;
9   }
12 struct Foo : Base
14   virtual ~Foo();
15   virtual Base* clone() {
16     return new Foo();
17   }
20 int main()
22   Base* f = new Foo();
23   f->clone();
24   return 0;
27 /* { dg-final { scan-tree-dump-not "OBJ_TYPE_REF" "optimized"  } } */
28 /* { dg-final { scan-assembler-not "_ZN3Foo5cloneEv" } } */