
ali f wrote:
Hi again,
ok, here's my actual real world situation:
win->on_mouse_move.connect( args_cast<2, bool(int,int,bool,int)>( ( lambda::var(x) = lambda::_1, lambda::var(y) = lambda::_2, true ) ) );
The following: win->on_mouse_move.connect( ( lambda::var(x) = lambda::_1, lambda::var(y) = lambda::_2, lambda::_4, true ) ); would be Lambda's way to make it accept four arguments and only use the first two; it doesn't subscribe to boost::bind's philosophy of automatically ignoring extra arguments. Unfortunately, Lambda doesn't have _4, which makes the suggested workaround a bit limited. :-) Your attempt at using boost::bind with it didn't work probably because you didn't specify a return type. Try boost::bind<bool>.