]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
New test from GNATS.
authorGabriel Dos Reis <gdr@gcc.gnu.org>
Sat, 11 Aug 2001 18:25:23 +0000 (18:25 +0000)
committerGabriel Dos Reis <gdr@gcc.gnu.org>
Sat, 11 Aug 2001 18:25:23 +0000 (18:25 +0000)
From-SVN: r44801

gcc/testsuite/g++.dg/eh/omit-frame-pointer.C [new file with mode: 0644]

diff --git a/gcc/testsuite/g++.dg/eh/omit-frame-pointer.C b/gcc/testsuite/g++.dg/eh/omit-frame-pointer.C
new file mode 100644 (file)
index 0000000..3792e11
--- /dev/null
@@ -0,0 +1,25 @@
+// { dg-do run }
+// { dg-options -fomit-frame-pointer }
+
+#include <iostream>
+
+class Bug
+{
+};
+
+int throw_bug()
+{
+       throw Bug();
+
+       return 0;
+}
+
+int main()
+{
+       try {
+               std::cout << throw_bug();
+       } catch (Bug bug) {
+       };
+       
+       return 0;
+}