[C++-sig] Wrap a c++ function that returns boost::shared_ptr<> type?

David Abrahams dave at boostpro.com
Thu Dec 18 19:17:32 CET 2008


on Wed Dec 17 2008, "Roman Yakovenko" <roman.yakovenko-AT-gmail.com> wrote:

> 2008/12/18 lin yun <yunlin07 at gmail.com>:
>> Hi, folks:
>>
>> I am trying to wrap a c++ function that returns a boost::shared_ptr<some
>> class> type using boost.python, is that possible?
>
> Yes. I believe Py++ deals with boost::shared_ptr without invoking the
> user. Just use default call policy.

Boost.Python itself also deals with shared_ptr without involving the
user.

-- 
Dave Abrahams
BoostPro Computing
http://www.boostpro.com


More information about the Cplusplus-sig mailing list