[Patch] Use variadic templates for tr1::is_function
Paolo Carlini
pcarlini@suse.de
Tue Apr 10 18:00:00 GMT 2007
Doug Gregor wrote:
> That's not a valid use of result_of.
>
> result_of<F(A1, A2, ..., AN)>::type is the return type when calling a
> function object of type F with arguments a1, a2, ..., aN of types A1,
> A2, ..., AN, respectively. In your example use, F is "int", which is
> not a valid function object.
Humm, ok, thanks, I'm still trying to digest the whole idea...
> Now, you could do something like:
>
> result_of<int(double)(double)>::type
>
> That would be int.
But, unless I'm doing some stupid mistake, it doesn't compile...
Paolo.
More information about the Libstdc++
mailing list