blob: 07c5155ac06e3f77ad25c81f8c812563acc39230 [file] [log] [blame]
// PR c++/97675
// { dg-additional-options -Wno-exceptions }
struct Base { };
struct Child : Base { };
int main() {
try { throw Child(); }
catch (Base const&) { }
catch (Child const&) { } // { dg-bogus "exception of type .Child. will be caught by earlier handler" }
}