I'd appreciate help figuring out what going on in this problem that's come up in my code which I've reduced to the following:
typedef unsigned short ushort;
template<typename T = ushort*>
struct Foo
{
};
// Specialization -- works when not a specialization
template<
template<typename,typename> class Container ,
template<typename , template<typename,typename> class> class MetaFunction
>
struct Foo<Container<ushort,typename MetaFunction<ushort,Container>::Type> >
{
//typedef Container<ushort,typename MetaFunction<ushort,Container>::Type> TestType; // OK
};
int main()
{
}
On compilation (gcc 5.4.0) I get the error:
Test.cpp:14:8: error: template parameters not deducible in partial specialization:
struct Foo<Container<ushort,typename MetaFunction<ushort,Container>::Type> >
^
Test.cpp:14:8: note: ‘template<class, template<class, class> class<template-parameter-2-2> > class MetaFunction’
Oddly, the argument Container<ushort,typename MetaFunction<ushort,Container>::Type>
to the specialization appears to be valid.