Exposing boost::scoped_ptr in boost::python
Posted
by Rupert Jones
on Stack Overflow
See other posts from Stack Overflow
or by Rupert Jones
Published on 2010-04-05T07:57:23Z
Indexed on
2010/04/05
8:03 UTC
Read the original article
Hit count: 283
Hello, I am getting a compile error, saying that the copy constructor of the scoped_ptr
is private with the following code snippet:
class a {};
struct s
{
boost::scoped_ptr<a> p;
};
BOOST_PYTHON_MODULE( module )
{
class_<s>( "s" );
}
This example works with a shared_ptr though. It would be nice, if anyone knows the answer. Thanks
© Stack Overflow or respective owner