2018-11-07 Richard Biener <rguenther@suse.de>
[official-gcc.git] / gcc / testsuite / g++.dg / opt / pr71210-1.C
blob03b1fb55c5094601bc574354fdd5fed9423f1c5a
1 // PR c++/71210
2 // { dg-do compile }
3 // { dg-options "-O2" }
5 #include <typeinfo>
7 void f1 (const std::type_info&) __attribute__((noreturn));
8 struct S1 { ~S1 (); };
9 struct S2
11   virtual S1 f2 () const { f1 (typeid (*this)); }
12   S1 f3 () const { return f2 (); }
14 void f4 () { S2 a; a.f3 (); }