From: Paolo Carlini Date: Thu, 4 Oct 2012 23:19:46 +0000 (+0000) Subject: re PR c++/53403 (Function template friend denied access to private types of granting... X-Git-Tag: upstream/12.2.0~73800 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=87a52ec1f65f29c71b48c2d9e6508c5d090bf819;p=platform%2Fupstream%2Fgcc.git re PR c++/53403 (Function template friend denied access to private types of granting template class.) 2012-10-04 Paolo Carlini PR c++/53403 * g++.dg/template/friend53.C From-SVN: r192108 --- diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index f7003f989cb..734d0460124 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,3 +1,8 @@ +2012-10-04 Paolo Carlini + + PR c++/53403 + * g++.dg/template/friend53.C + 2012-10-04 Eric Botcazou * lib/gcc-dg.exp (cleanup-ada-spec): New procedure. diff --git a/gcc/testsuite/g++.dg/template/friend53.C b/gcc/testsuite/g++.dg/template/friend53.C new file mode 100644 index 00000000000..6cbbb2b0993 --- /dev/null +++ b/gcc/testsuite/g++.dg/template/friend53.C @@ -0,0 +1,23 @@ +// PR c++/53403 + +template +class Foo +{ + typedef void type; + template friend void f(); +public: + Foo() {} +}; + +template class Foo; + +template +void f() +{ + typedef Foo::type type; +} + +int main() +{ + f(); +}