
4 Jul
2004
4 Jul
'04
8:59 a.m.
"Andy Little" <andy@servocomm.freeserve.co.uk> wrote
"Doug Gregor" <dgregor@cs.indiana.edu> wrote
If we had "smarter" versions of std::plus, std::minus, etc. that played well with result_of, I think that would solve the issue reasonably well.
This is the remaining problem. If there are to be these plus, minus functors where are they to reside or will they be the old favourites?
FWIW I'd go for something like this: result_of<operator_plus(int,int)>::type z = operator_plus()(x,y); result_of<operator_minus(int,int)>::type z = operator_minus()(x,y); result_of<operator_multiplies(int,int)>::type z = operator_multiplies()(x,y); regards Andy Little