
13 Oct
2009
13 Oct
'09
1:06 a.m.
On Monday 12 October 2009 04:07:26 Boris Schaeling wrote:
Is it possible to simplify this code without defining a function pointer?
No, but please see recent discussions on cplusplus-sig for ideas for the future.
----- struct X { void y(std::string) { } std::string y() { return ""; } };
std::string (X::*get_y)() = &X::y;
class_<X>("X").add_property("y", get_y); -----
Regards, Ravi