Fortran: Fix PR 47485.
[gcc.git] / gcc / testsuite / g++.dg / asan / pr78651.C
blob09f1be538c3754040f89b18d20776956931a8e7a
1 // PR sanitizer/78651
2 // { dg-do run }
3 // { dg-additional-options "-fpic" { target fpic } }
5 struct A { };
7 namespace {
9 void thisThrows () {
10   throw A();
13 struct SomeRandomType {};
16 int main() {
17   try {
18     thisThrows();
19   }
20   catch (SomeRandomType) {
21     throw;
22   }
23   catch (A) {
24   }
25   return 0;