From 46ab14ebb47c79eae96039996e0b3cffe6558ee3 Mon Sep 17 00:00:00 2001 From: "Ralf W. Grosse-Kunstleve" Date: Fri, 5 Jul 2024 12:33:19 -0700 Subject: [PATCH] Add missing `explicit` to resolve clang-tidy error. --- include/pybind11/detail/smart_holder_value_and_holder_support.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/pybind11/detail/smart_holder_value_and_holder_support.h b/include/pybind11/detail/smart_holder_value_and_holder_support.h index 9d949dd60..6c4469de8 100644 --- a/include/pybind11/detail/smart_holder_value_and_holder_support.h +++ b/include/pybind11/detail/smart_holder_value_and_holder_support.h @@ -19,7 +19,7 @@ template struct value_and_holder_helper { const VHType *loaded_v_h; - value_and_holder_helper(const VHType *loaded_v_h) : loaded_v_h{loaded_v_h} {} + explicit value_and_holder_helper(const VHType *loaded_v_h) : loaded_v_h{loaded_v_h} {} bool have_holder() const { return loaded_v_h->vh != nullptr && loaded_v_h->holder_constructed();