
19 Jul
2008
19 Jul
'08
4:31 a.m.
AMDG Robert Jones wrote:
Gives a compiler error, which I think tells me that my lambda expression, _1 == 3 does not provide the argument_type typedef. I thought lambda expressions were careful to to do this. What am I doing wrong?
Lambda can't provide argument_type typedefs in general. Consider the following: (_1 == 3)(1.0) (_1 == 3)(10) Both of these are legal. The same function object can be called with either a double or an int. There is no unique argument type. In Christ, Steven Watanabe