i am wrapping an abstract class &quot;Actor&quot; which is to be implemented partially in Python, using a wrapper class that looks like this:<br><br>class PyActor : public Actor, public wrapper&lt;Actor&gt; {<br>public:<br>
&nbsp; ....<br>};<br><br>the boost.python export code looks like this:<br><br>class_&lt;PyActor, boost::noncopyable&gt;(&quot;Actor&quot;);<br><br>this would be all good and well, until I decided to pass back Actor pointers from methods e.g. like Actor::get_parent(), which have to resolve back to original python objects, for which the FAQ suggests using shared_ptr, if altering the underlying code was possible - which it is.<br>
<br>so there is now a method in Actor declared like this:<br><br>// assumed: typedef boost::shared_ptr&lt;Actor&gt; ActorPtr;<br><br>ActorPtr Actor::get_parent();<br><br>unfortunately calling that method gives me a new wrapped Actor python object - not exactly what the FAQ promised. but I read that the shared_ptr&lt;&gt; has to be declared as the object holder, like this:<br>
<br>class_&lt;PyActor, ActorPtr, boost::noncopyable(&quot;Actor&quot;);<br><br>which I did, but that gives me a compiler error if Actor is abstract, and if I declare it non-abstract, calls to wrapping PyActor methods fail in Python. I guess that this approach does not work with wrapper classes, or the syntax is different.<br>
<br>how do I have to do it? I searched through the mailing list but found nothing viable so far.<br><br>thanks in advance!<br><br>