Example of how to do std::enable_if<...> with multiple conditions
Simply use &&
like this:
std::enable_if<CONDITION1::value && CONDITION2::value, T>
Full example:
template<class T, class I>
constexpr typename std::enable_if<std::is_enum<T>::value && std::is_integral<I>::value, I>::type operator|(T lhs, I rhs)
{
return static_cast<typename std::underlying_type<T>::type>(lhs) | rhs;
}