我的情况就像这个人为的例子:
template<class TFeature> struct Controller {};
template<class TController,typename T> struct Feature {
typedef Feature<TController,T> FeatureType;
};
typedef Controller<Feature::FeatureType,int> DefaultController;
控制器被模板化以接受功能,我的问题是某些功能需要控制器的类型作为模板参数。这使得示例最后一行的 typedef 无法编译。
这是可能的还是我需要重新考虑设计?