Attempting to use std::enable_if_t in the template parameters gives an error
doesn’t name a type
, although type_traits connected, standard 11. What could be the problem?
Attempting to use std::enable_if_t in the template parameters gives an error
doesn’t name a type
, although type_traits connected, standard 11. What could be the problem?
std::enable_if_t is from C ++ 14, in C ++ 11 there is only std::enable_if<C, T>::type
However, enable_if_t is an alias and you can write it yourself:
template<bool C, class T = void> using enable_if_t = typename std::enable_if<C, T>::type; Source: https://ru.stackoverflow.com/questions/500735/
All Articles