Debian Codegraph @

gcc/testsuite/g++.dg/ipa/devirt-28a.C

raw
1 // PR c++/58678
2 // { dg-options "-O3 -flto -shared -fPIC -Wl,--no-undefined" }
3 // { dg-do link { target { { gld && fpic } && shared } } }
4 // { dg-require-effective-target lto }
5
6 struct A {
7 virtual ~A();
8 };
9 struct B : A {
10 virtual int m_fn1();
11 };
12 void fn1(B* b) {
13 delete b;
14 }
15
16 int main() {}