Using PYBIND11_SH_DEF for test_override_cache_helper introduced by PR #3465.

This commit is contained in:
Ralf W. Grosse-Kunstleve 2021-11-15 14:59:46 -08:00
parent f4fab85d87
commit 8a7643f471
2 changed files with 2 additions and 2 deletions

View File

@ -62,7 +62,7 @@ PYBIND11_EMBEDDED_MODULE(widget_module, m) {
} }
PYBIND11_EMBEDDED_MODULE(trampoline_module, m) { PYBIND11_EMBEDDED_MODULE(trampoline_module, m) {
py::class_<test_override_cache_helper, test_override_cache_helper_trampoline, std::shared_ptr<test_override_cache_helper>>(m, "test_override_cache_helper") py::class_<test_override_cache_helper, test_override_cache_helper_trampoline, PYBIND11_SH_DEF(test_override_cache_helper)>(m, "test_override_cache_helper")
.def(py::init_alias<>()) .def(py::init_alias<>())
.def("func", &test_override_cache_helper::func); .def("func", &test_override_cache_helper::func);
} }

View File

@ -398,7 +398,7 @@ TEST_SUBMODULE(virtual_functions, m) {
.def("A_value", &OverrideTest::A_value) .def("A_value", &OverrideTest::A_value)
.def("A_ref", &OverrideTest::A_ref); .def("A_ref", &OverrideTest::A_ref);
py::class_<test_override_cache_helper, test_override_cache_helper_trampoline, std::shared_ptr<test_override_cache_helper>>(m, "test_override_cache_helper") py::class_<test_override_cache_helper, test_override_cache_helper_trampoline, PYBIND11_SH_DEF(test_override_cache_helper)>(m, "test_override_cache_helper")
.def(py::init_alias<>()) .def(py::init_alias<>())
.def("func", &test_override_cache_helper::func); .def("func", &test_override_cache_helper::func);