Loki的TypeList技术解析(四)

2014-11-23 23:41:32 · 作者: · 浏览: 7
t so that the most derived types appear first // Invocation (TList is a typelist): // DerivedToFront ::Result // returns the reordered TList //////////////////////////////////////////////////////////////////////////////// template struct DerivedToFront; template <> struct DerivedToFront { typedef NullType Result; }; template struct DerivedToFront< Typelist > { private: typedef typename MostDerived ::Result TheMostDerived; typedef typename Replace ::Result Temp; typedef typename DerivedToFront ::Result L; public: typedef Typelist Result; }; } // namespace TL