Boost logo

Boost :

From: Peter Dimov (pdimov_at_[hidden])
Date: 2004-08-18 18:16:35


Jonathan Turkanis wrote:
>
> For overload resolution by arity one could write:
>
> boost::overload< by_arity<3> >::resolve(&C::g)
>
> but that's still a bit cumbersome.

#include <boost/bind.hpp>

struct V
{
    int f();
    int f(int);
};

int main()
{
    boost::bind( &V::f, _1 ); // V::f()
    boost::bind( &V::f, _1, _2 ); // V::f(int)
}

;-)


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk