Hi again, Doug,
for the first time I'm looking into some details of result_of...
and I have some basic curiosities. For example, is not at all clear
to me why it doesn't work at all with plain functions (vs function
pointers, etc.). Can you do a bit of popularization and explain why
this kind of code path cannot be followed, in principle:
#include <type_traits>
#include <cassert>
template<typename>
struct result_of;
template<typename _Res, typename... _ArgTypes>
struct result_of<_Res(_ArgTypes...)>
{ typedef _Res type; };
int main()
{
using std::is_same;
assert( (is_same<result_of<int (double)>::type, int>::value) );
}
???