summaryrefslogtreecommitdiff
path: root/gcc/testsuite/g++.old-deja/g++.pt/friend41.C
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/testsuite/g++.old-deja/g++.pt/friend41.C')
-rw-r--r--gcc/testsuite/g++.old-deja/g++.pt/friend41.C21
1 files changed, 21 insertions, 0 deletions
diff --git a/gcc/testsuite/g++.old-deja/g++.pt/friend41.C b/gcc/testsuite/g++.old-deja/g++.pt/friend41.C
new file mode 100644
index 000000000..e3a6c0c3f
--- /dev/null
+++ b/gcc/testsuite/g++.old-deja/g++.pt/friend41.C
@@ -0,0 +1,21 @@
+// { dg-do assemble }
+// Origin: Mark Mitchell <mark@codesourcery.com>
+
+template <class T>
+class S {
+public:
+ template <class U>
+ class C {
+ public:
+ void f() { S::i = 3; }
+ };
+
+ template <class U>
+ friend class C;
+
+private:
+ static int i;
+};
+
+
+template void S<int>::C<double>::f();