From: Kriang Lerdsuwanakij Date: Sun, 3 Aug 2003 09:42:00 +0000 (+0000) Subject: re PR c++/9453 (ICE in is_specialization_of, at cp/pt.c:860) X-Git-Tag: releases/gcc-3.4.0~4419 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=79572cb19be18c26f3558f070bbca94e1fcb6230;p=thirdparty%2Fgcc.git re PR c++/9453 (ICE in is_specialization_of, at cp/pt.c:860) PR c++/9453 * g++.dg/template/friend15.C: New test. From-SVN: r70115 --- diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index de8342ca9e71..e1fa217f1fc4 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,3 +1,8 @@ +2003-08-03 Kriang Lerdsuwanakij + + PR c++/9453 + * g++.dg/template/friend15.C: New test. + 2003-08-03 Neil Booth * lib/dg-pch.exp: Work round PCH bug. diff --git a/gcc/testsuite/g++.dg/template/friend15.C b/gcc/testsuite/g++.dg/template/friend15.C new file mode 100644 index 000000000000..4acbf2d1a56b --- /dev/null +++ b/gcc/testsuite/g++.dg/template/friend15.C @@ -0,0 +1,19 @@ +// { dg-do compile } + +// Origin: Wolfgang Bangerth + +// PR c++/9453 +// Access checking when template friend is defined in class. + +template class X { + private: + struct Inner; + + template + friend typename X::Inner * foo () { return 0; } +}; +template class X; + +struct U { + void bar () { foo (); } +};