【发布时间】:2013-09-09 05:06:20
【问题描述】:
template <template <typename> class container_type>
class MyClass
{
class Internal{
};
};
我想以如下方式使用这个类(或它的正确外观)......
MyClass(std::list);
...所以在 MyClass 中 container_type 被声明为/typedef'd 为:
std::list<Internal*>
这样的事情有可能吗?
【问题讨论】:
-
你对 Stroustrup 缩进风格有什么看法...?
-
很难在视觉上匹配左大括号
-
@greatwolf 你一般不会根据编程风格进行编辑。
标签: c++ templates c++11 template-templates