compiler : g++ of gcc4.5.2(minGW)
os : windows xp sp3(32bits)
template<typename T, template<typename> class CONT = AccumulationTraits >
class Accum
{
public :
static typename CONT<T>::AccT accum(T const *beg, T const *end)
{
typename CONT<T>::AccT total = CONT<T>::zero();
while(beg != end)
{
total += *beg;
++beg;
}
return total;
}
};
template<typename T, template<typename> class CONT = AccumulationTraits >
inline typename CONT<T>::AccT accum(T const *beg, T const *end)
{
return Accum<T, CONT>::accum(beg, end);
}
The code like this work fine on gcc4.5.2
Is this a legal feature of C++0x or a special feature support by gcc?
I can't find any information from the C++0x faq maintain by Bjarne Stroustrup(maybe I missed it)
Thanks a lot