14 Jan
2003
14 Jan
'03
3:18 p.m.
Using Boost/Python, how does one overload methods? For instance: struct Bar { void func( const std::string& s ); void func( int i ); }; BOOST_PYTHON_MODULE( Foo ) { class_<Bar>( "Bar" ) .def( "func", &Bar::func ) .def( ??? ) ; } The reference documentation discusses the BOOST_PYTHON_MEMBER_FUNCTION_OVERLOADS macro, but it only seems to apply to methods with default arguments. --bruce