Mercurial > hg > CbC > CbC_gcc
view gcc/testsuite/g++.dg/opt/vt4.C @ 131:84e7813d76e9
gcc-8.2
author | mir3636 |
---|---|
date | Thu, 25 Oct 2018 07:37:49 +0900 |
parents | 04ced10e8804 |
children |
line wrap: on
line source
// PR c++/50243 // { dg-do compile } // { dg-options "-O" } // { dg-add-options bind_pic_locally } // { dg-final { scan-assembler-not "_ZTV.A" } } void foo (); struct A { ~A () { } virtual void a () = 0; virtual void b () = 0; virtual void c () = 0; }; struct B : public A { ~B () { foo (); } void a () { foo (); } void b () { foo (); } void c () { delete this; } }; void test () { A *y = new B (); y->a (); y->b (); y->c (); }