
3 Mar
2010
3 Mar
'10
3:13 p.m.
Jesse Perla wrote:
Yup. I think it is very useful. Though without getting it to work with phoenix or std::tr1::bind, I think it have limited appeal. I also would guess (though haven't tested) that the trick fails with boost::function as well.
Perhaps this is because void some_f( int ) {} boost::bind( &some_f, _1 )( 1, 1, 1, 1, 1 ); compiles and works? But you probably mean that boost::bind( &some_f, _1 )( "some_other_type" ); doesn't compile, whereas is_callable< BOOST_TYPEOF( boost::bind( &some_f, _1 ) ), boost::mpl::vector< std::string > > is true_. I see. I will check if this indirection can be detected somewhere... Cheers, Rutger