summaryrefslogtreecommitdiff
path: root/gcc/testsuite/g++.old-deja/g++.pt/crash41.C
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/testsuite/g++.old-deja/g++.pt/crash41.C')
-rw-r--r--gcc/testsuite/g++.old-deja/g++.pt/crash41.C13
1 files changed, 13 insertions, 0 deletions
diff --git a/gcc/testsuite/g++.old-deja/g++.pt/crash41.C b/gcc/testsuite/g++.old-deja/g++.pt/crash41.C
new file mode 100644
index 000000000..452ba91dc
--- /dev/null
+++ b/gcc/testsuite/g++.old-deja/g++.pt/crash41.C
@@ -0,0 +1,13 @@
+// { dg-do compile }
+// Origin: Mark Mitchell <mark@codesourcery.com>
+
+template <int> struct S1{};
+
+struct S2 { int i; };
+
+template <class T>
+void f(S2 s2) {
+ S1<s2.i> s1; // { dg-error "" }
+}
+
+template void f<int>(S2);