pybind / pybind11_protobuf

Pybind11 bindings for Google's Protocol Buffers
Other
54 stars 33 forks source link

Introduce `PYBIND11_PROTOBUF_ASSUME_FULL_ABI_COMPATIBILITY` (see proto_cast_util.h): #130

Closed copybara-service[bot] closed 10 months ago

copybara-service[bot] commented 11 months ago

Introduce PYBIND11_PROTOBUF_ASSUME_FULL_ABI_COMPATIBILITY (see proto_cast_util.h):

This macro can be defined by users certain about ABI compatibility between all Python extensions in their environment using protobufs. If defined, passing protos from Python to C++ may skip serialization/deserialization. — Note that this change makes the default behavior safer, but unless PYBIND11_PROTOBUF_ASSUME_FULL_ABI_COMPATIBILITY is defined, the runtime performance may be noticably slower.