template<typename T> class A {
template<typename U> class B;
template<typename U> class C;
template<typename U> class B {
typedef C<U> D;
D *c;
T u;
};
template<typename U> class C { // It works fine if I change 'C' to 'D' here.
typedef B<U> B;
B *b;
T v; //VC2008 complains about this line, that T is undefined.
};
};
A<int> a;


Reply With Quote

Bookmarks