aboutsummaryrefslogtreecommitdiff
path: root/gcc/testsuite
diff options
context:
space:
mode:
authorMark Mitchell <mark@codesourcery.com>2004-02-03 20:01:59 +0000
committerMark Mitchell <mmitchel@gcc.gnu.org>2004-02-03 20:01:59 +0000
commit18f5be99b4e9b8104748413f4538bb620d9f0a45 (patch)
treee5c58099c4f700145cfd88375f09a790ad2b3020 /gcc/testsuite
parent4bfb8bbaf6294daa459f1f0d8216796001998afd (diff)
downloadgcc-18f5be99b4e9b8104748413f4538bb620d9f0a45.zip
gcc-18f5be99b4e9b8104748413f4538bb620d9f0a45.tar.gz
gcc-18f5be99b4e9b8104748413f4538bb620d9f0a45.tar.bz2
re PR c++/13925 (Bug while befriending specializations)
PR c++/13925 * decl.c (start_function): Do not call pushdecl for any instantiation or specialization of a primary template. PR c++/13925 * g++.dg/template/lookup5.C: New test. From-SVN: r77187
Diffstat (limited to 'gcc/testsuite')
-rw-r--r--gcc/testsuite/ChangeLog5
-rw-r--r--gcc/testsuite/g++.dg/template/lookup5.C17
2 files changed, 22 insertions, 0 deletions
diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog
index 00c0b71..f31c5c5 100644
--- a/gcc/testsuite/ChangeLog
+++ b/gcc/testsuite/ChangeLog
@@ -1,5 +1,10 @@
2004-02-03 Mark Mitchell <mark@codesourcery.com>
+ PR c++/13925
+ * g++.dg/template/lookup5.C: New test.
+
+2004-02-03 Mark Mitchell <mark@codesourcery.com>
+
PR c++/13950
* g++.dg/template/lookup4.C: New test.
diff --git a/gcc/testsuite/g++.dg/template/lookup5.C b/gcc/testsuite/g++.dg/template/lookup5.C
new file mode 100644
index 0000000..022202a
--- /dev/null
+++ b/gcc/testsuite/g++.dg/template/lookup5.C
@@ -0,0 +1,17 @@
+// PR c++/13925
+
+namespace N {
+ template <class T> void f(T);
+
+ namespace M {
+ class A {
+ friend void f<int>(int);
+ };
+ }
+
+ template <class T> void f(T) {}
+ template <> void f<int>(int )
+ {
+ f<long>(0);
+ }
+}