2019-03-19 Mixing pybind11 modulesΒΆ

My scenario was the following: expose a C++ class in one C++ module exported with pybind11, then create a function in a another C++ module returning a result of this class. The solution for that is described in the following issue Return type that is implemented in another library with another set of python bindings, which links to this part of the documentation Custom type casters. and implemented in this module somewhere in cbenchmark_dot.cpp.