[C++-sig] [pybindgen] references?
Alan Baljeu
alanbaljeu at yahoo.com
Tue Nov 4 01:18:47 CET 2008
From: Stefan Seefeld <seefeld at sympatico.ca>
>If you need fine-grained control about argument passing policies (as
>soon as you need reference-semantics, you have to be careful about
>lifetime management, for example), you are better off writing
>boost.python bindings manually, I would suggest.
>
>Regards,
> Stefan
void baz(foo &x);
If I have a foo, I call baz with it, foo's contents may change but it's still the same object. I don't see an issue here, unless foo is a smart pointer type.
And the only smart pointers I receive are weak references, and I'm assuming/planning that the referenced object doesn't get destroyed. So I'm feeling safe to not concern myself.
Alan
__________________________________________________________________
Be smarter than spam. See how smart SpamGuard is at giving junk email the boot with the All-new Yahoo! Mail. Click on Options in Mail and switch to New Mail today or register for free at http://mail.yahoo.ca
More information about the Cplusplus-sig
mailing list