A nested typedef named type, that is the return type of the function type in result_of's template parameter.
typedef /* implementation details */ type; ();
This can be used to specify the operator within function objects that have multiple signatures. result_of is typically used in template programming (as opposed to just determining the return type).
namespace std::tr1{ #include <functional> #include <iostream> #include <typeinfo> typedef double (*FP)(int, short); int main() { std::cout << typeid(std::tr1::result_of<FP>::type).name() << '\n'; std::cout << typeid(result_of<less<int>(int, int)>::type).name() << '\n' }; }
result
double bool