A template template parameter can only involve template parameters, not template arguments. This should work:
template<template<class, class> class C, class A>
static std::pair<C<std::string, A>, C<std::string, A> > Check(const typename C<std::string, A>::iterator &beg, const typename C<std::string, A>::iterator &end)
{
//....
}
As @Jarod42 points out in the comments, the above signature doesn't allow type deduction for C
and A
. And it doesn't match your use case anyway; for that, use this, which will deduce C
and A
just fine:
template<template<class, class> class C, class A>
static std::pair<C<std::string, A>, C<std::string, A> > Check(const C<std::string, A> &container)
{
//....
}