binutils-gdb/ld/testsuite/ld-plugin/pr12696-1.cc

8 lines
290 B
C++

/* { dg-lto-do link } */
/* { dg-lto-options {{-ftoplevel-reorder -flto -flto-partition=none} {-ftoplevel-reorder -flto -flto-partition=1to1}} } */
/* { dg-extra-ld-options {-r -nostdlib} } */
struct Foo { virtual ~Foo(); };
struct Bar:public Foo { Bar() { } };
void Func() { new Bar(); }