EmmanueD
public cpp v1 · immutabletemplate <class T> class has_sub_type{ template <class wrapped> class wrapper { }; template <u> static size_1 test(wrapper<typename u::type>*); template <u> static size_2 test(...);public: static const bool value = (sizeof(test<T>(0)) == 1);};