PR lto/84212 - -Wno-* does not disable warnings from -flto link stage
[official-gcc.git] / gcc / testsuite / g++.dg / warn / pr61945.C
blob5584d841692fdacf2ea4a9bca725af686c206f44
1 // PR c++/61945
2 // { dg-do compile }
3 // { dg-options "-Woverloaded-virtual" }
5 class A {
6   virtual int foo ();   // { dg-warning "was hidden" }
7 };
8 class B : A {
9   template <typename>
10   void foo ();          // { dg-warning "by .B::foo\\(\\)." }