<分区>
Possible Duplicate:
Where and why do I have to put “template” and “typename” on dependent names?
我有以下星座:
template<typename T>
class A{
template<typename U>
A<U> f()const;
}
template<typename T, typename U>
A<U> F(const A<T> &I)
{
return I.f<U>();//this does not work
}
标记行上的编译器错误是:
错误:“>”标记之前的预期初始值设定项
那么我该如何正确地写这行呢?