enable class's member depending on template
I already know that you can enable (or not) a class's method using std::enable_if for exemple: template<size_t D, size_t E> class Field { ... size_t offset(const std::array<float,D>& p) const { ... } template<typename TT = size_t> typename std::enable_if<D!=E, TT>::type offset(const std::array<float,E>& p) const { return offset(_projection(p)); } ... }; This helps not being able to call function that are invalid in a specific case as well as removing overloading errors ... which, to me, is very nice ! I'd like to go further and make some of my class's members being present only if the are