template/friend/nested class bug report

Vijay Menon vsm@kidar.org
Tue Sep 19 16:09:00 GMT 2000


Error:

test.cpp:18: Internal compiler error.
test.cpp:18: Please submit a full bug report.
test.cpp:18: See
<URL: http://www.gnu.org/software/gcc/faq.html#bugreport > for
instructions.    

------------------------------------------------
g++ version: gcc version 2.95.3 19991030 (prerelease)

system type: pentium3/linux (mandrake 7.1)

options: none

test.cpp:
------------------------------------------------
template <class T2>
class C;

template <class T1>
class A {
public:
    class B {
    public:
        int bar(C<int> c) { return c.foo; }
    };
};

template <class T2>
class C {
public:
    template <class T1>
    friend class A<T1>::B;
private:
    int foo;
};
------------------------------------------------


More information about the Gcc-bugs mailing list