------- Additional Comments From bangerth at dealii dot org 2005-05-02 18:54 ------- What is going wrong is this: the name 'S' may refer to both the local typedef in the base class 'A' as well as to the global structure '::S'. If I write either friend class A< A< ::S>::S>; or friend class A< ::S>; then the code is accepted by gcc. I don't know whether the ambiguity makes the code invalid. As a reference point, icc accepts the code in strict mode. W.
-- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=21146