summaryrefslogtreecommitdiff
path: root/gcc/testsuite/g++.dg/eh/pr38662.C
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/testsuite/g++.dg/eh/pr38662.C')
-rw-r--r--gcc/testsuite/g++.dg/eh/pr38662.C13
1 files changed, 13 insertions, 0 deletions
diff --git a/gcc/testsuite/g++.dg/eh/pr38662.C b/gcc/testsuite/g++.dg/eh/pr38662.C
new file mode 100644
index 000000000..5da0f9763
--- /dev/null
+++ b/gcc/testsuite/g++.dg/eh/pr38662.C
@@ -0,0 +1,13 @@
+// { dg-do compile { target { { i?86-*-* x86_64-*-* } && ilp32 } } }
+class E { };
+
+class T {
+ int foo(bool a) throw (E) __attribute__((regparm(1)));
+ int bar(bool b) __attribute__((regparm(1)));
+};
+
+int T::bar(bool b)
+{
+ return (b ? 1 : 2);
+}
+