From 67ae480c8d57043fbbcd88c4b6047481acc388a7 Mon Sep 17 00:00:00 2001 From: "Ralf W. Grosse-Kunstleve" Date: Fri, 12 Jul 2024 09:09:54 -0700 Subject: [PATCH] Work In Progress PiperOrigin-RevId: 651793092 --- pybind11_protobuf/native_proto_caster.h | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/pybind11_protobuf/native_proto_caster.h b/pybind11_protobuf/native_proto_caster.h index dfdce39..fd7f244 100644 --- a/pybind11_protobuf/native_proto_caster.h +++ b/pybind11_protobuf/native_proto_caster.h @@ -91,6 +91,20 @@ struct type_caster< : public pybind11_protobuf::proto_caster< ProtoType, pybind11_protobuf::native_cast_impl> {}; +#if defined(PYBIND11_HAVE_HOLDER_CASTER_WITH_SMART_HOLDER_SUPPORT) + +template +struct copyable_holder_caster_shared_ptr_with_smart_holder_support_enabled< + ProtoType, enable_if_t::value>> + : std::false_type {}; + +template +struct move_only_holder_caster_unique_ptr_with_smart_holder_support_enabled< + ProtoType, enable_if_t::value>> + : std::false_type {}; + +#endif // PYBIND11_HAVE_HOLDER_CASTER_WITH_SMART_HOLDER_SUPPORT + // NOTE: If smart_holders becomes the default we will need to change this to // type_caster, ... // Until then using that form is ambiguous due to the existing specialization