前置依赖:
integral_constant
源码实现:
template<typename _Pp> struct __not_<_Pp> : public __bool_constant<!bool(_Pp::value)>::type { };
返回结果为 true_type 或者 false_type
值得注意的是这里使用了一下强制转换, 也就是其它提供了 value 接口的类也可以进行取反操作, 提供了很高的灵活性