summaryrefslogtreecommitdiff
path: root/gcc/testsuite/g++.old-deja/g++.pt/memtemp97.C
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/testsuite/g++.old-deja/g++.pt/memtemp97.C')
-rw-r--r--gcc/testsuite/g++.old-deja/g++.pt/memtemp97.C17
1 files changed, 17 insertions, 0 deletions
diff --git a/gcc/testsuite/g++.old-deja/g++.pt/memtemp97.C b/gcc/testsuite/g++.old-deja/g++.pt/memtemp97.C
new file mode 100644
index 000000000..e00c3bb28
--- /dev/null
+++ b/gcc/testsuite/g++.old-deja/g++.pt/memtemp97.C
@@ -0,0 +1,17 @@
+// { dg-do run }
+// Origin: Mark Mitchell <mark@codesourcery.com>
+
+template <class T> struct A {
+ template <class U> int f(U) { return 1; }
+};
+
+template <>
+template <class U>
+int A<int>::f(U) { return 0; }
+
+A<int> a;
+
+int main ()
+{
+ return a.f (3);
+}