Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
template <typename T, template <typename> class Bar> class Foo { Bar<T> bar; };
我正在尝试对此类进行专门化,该类的类型Foo<Bar<Foo>>是Bar具有 1 个模板参数的任意模板类。谁能告诉我如何做到这一点?另外,我不想坚持这个特定的模板类定义。如果它可以通过使用不同的定义来完成,Foo那也没关系。
Foo<Bar<Foo>>
Bar
Foo
编辑:我的意思是我希望专业化是类型Foo<Foo, Bar<Foo>>
Foo<Foo, Bar<Foo>>