mirror of
https://github.com/pybind/pybind11.git
synced 2026-06-06 06:11:25 +00:00
keep_alive call policy (analogous to Boost.Python's with_custodian_and_ward, fixes #62)
This commit is contained in:
@@ -21,6 +21,7 @@ void init_ex9(py::module &);
|
||||
void init_ex10(py::module &);
|
||||
void init_ex11(py::module &);
|
||||
void init_ex12(py::module &);
|
||||
void init_ex13(py::module &);
|
||||
|
||||
PYBIND11_PLUGIN(example) {
|
||||
py::module m("example", "pybind example plugin");
|
||||
@@ -37,6 +38,7 @@ PYBIND11_PLUGIN(example) {
|
||||
init_ex10(m);
|
||||
init_ex11(m);
|
||||
init_ex12(m);
|
||||
init_ex13(m);
|
||||
|
||||
return m.ptr();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user