[C++-sig] wrapping reference members

Sebastian Kraemer basti.kr at gmail.com
Wed Jul 22 16:16:05 CEST 2009

Hi all,
I'm a beginner of c++ and boost::python, so this may be a stupid
question. When I have the following class:

class Foo{
        float &a;

Is there some way to expose "a" in python? I would like to use it like a
normal python attribute, e.g. set it's value with "Foo().a = 3.1".

Thanks for any help,

More information about the Cplusplus-sig mailing list