以下是如何实现
(来自CPP Reference)
在这个定义下,对我来说,一个
std::is_function
的方法?template<class T>
struct is_function : std::integral_constant<
bool,
!std::is_const<const T>::value && !std::is_reference<T>::value
> {};
(来自CPP Reference)
在这个定义下,对我来说,一个
int
看起来是一个函数。我错过了什么吗?
!is_const
部分。 - aschepler