21 Jul
2007
21 Jul
'07
10:20 p.m.
It's possible to expose free functions through "thin wrappers": void f() { //... } void f_wrapper() { // ... some extra functionality to be done when called from Python only f(); } def("f", f_wrapper); But is it possible to write "thin wrappers" for member functions (without modifying the wrapped class)? struct foo { void f(); }; // f_wrapper defined somehow somewhere class_<foo>("foo") .def("f", f_wrapper???) Thanks, Marcin