aboutsummaryrefslogtreecommitdiff
path: root/gcc/testsuite/g++.old-deja/g++.jason/template4.C
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/testsuite/g++.old-deja/g++.jason/template4.C')
-rw-r--r--gcc/testsuite/g++.old-deja/g++.jason/template4.C21
1 files changed, 21 insertions, 0 deletions
diff --git a/gcc/testsuite/g++.old-deja/g++.jason/template4.C b/gcc/testsuite/g++.old-deja/g++.jason/template4.C
new file mode 100644
index 00000000000..7fcb45c3f9a
--- /dev/null
+++ b/gcc/testsuite/g++.old-deja/g++.jason/template4.C
@@ -0,0 +1,21 @@
+// Bug: g++ tries to instantiate ccList twice, and fails.
+// Build don't link:
+
+template<class T> class ccHandle{ };
+template <class T> class ccList;
+template <class T> class cc_List {
+public:
+ ccList <T> copy ();
+};
+
+template <class T> class ccList : public ccHandle < cc_List <T> > {
+public:
+ ccList (int);
+};
+
+template <class T>
+ccList <T> cc_List<T>::copy (){}
+
+int main (int, char **) {
+ ccList <int> size1();
+}