diff options
Diffstat (limited to 'gcc/testsuite/g++.old-deja/g++.eh/catch13.C')
-rw-r--r-- | gcc/testsuite/g++.old-deja/g++.eh/catch13.C | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/gcc/testsuite/g++.old-deja/g++.eh/catch13.C b/gcc/testsuite/g++.old-deja/g++.eh/catch13.C new file mode 100644 index 000000000..2e0fdc8e7 --- /dev/null +++ b/gcc/testsuite/g++.old-deja/g++.eh/catch13.C @@ -0,0 +1,19 @@ +// { dg-do assemble } +// { dg-options "-O2" } +// Copyright (C) 2001 Free Software Foundation, Inc. +// Contributed by Jakub Jelinek 2 May 2001 <jakub@redhat.com> + + +struct A; + +A *foo(); + +struct A { + A *a() { try { return foo(); } catch (...) {} } + void b(); + void c(); +}; + +void A::b() { + a()->c(); +} |