http://gcc.gnu.org/bugzilla/show_bug.cgi?id=45775
Summary: Private templated classes/structs inside a class. Product: gcc Version: 4.4.3 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c++ AssignedTo: unassig...@gcc.gnu.org ReportedBy: liran...@gmail.com Created attachment 21874 --> http://gcc.gnu.org/bugzilla/attachment.cgi?id=21874 Failing code Using GCC 4.4.3, and the attached source code, GCC does not error that the access to A::B<T> is illegal. According to the C++ spec: 11.8 Nested classes [class.access.nest] 1 A nested class is a member and as such has the same access rights as any other member. The members of an enclosing class have no special access to members of a nested class; the usual access rules (Clause 11) shall be obeyed. Note that A::C is erroring correctly. -- Configure bugmail: http://gcc.gnu.org/bugzilla/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.