2
0
mirror of https://github.com/boostorg/python.git synced 2026-01-21 05:02:17 +00:00
Files
python/test/bienstman3.cpp
2002-04-04 21:18:00 +00:00

34 lines
475 B
C++

#include <boost/python/module.hpp>
#include <boost/python/class.hpp>
#include <boost/mpl/type_list.hpp>
struct V
{
virtual void f() = 0;
};
struct B
{
B(const V&) {}
};
BOOST_PYTHON_MODULE_INIT(bienstman3_ext)
{
using namespace boost::python;
using boost::mpl::type_list;
module m("bienstman3_ext");
m
.add(
class_<V, boost::noncopyable>("V")
)
.add(
class_<B>("B")
.def_init(type_list<const V&>())
)
;
}