From a575ad6f94d2c20ccb333abb99b75efba598214e Mon Sep 17 00:00:00 2001 From: "Ralf W. Grosse-Kunstleve" Date: Fri, 29 Nov 2024 16:19:36 -0800 Subject: [PATCH] Add `PYBIND11_WARNING_DISABLE_CLANG("-Wgnu-zero-variadic-macro-arguments")` in test_smart_ptr.cpp This is the error message: ``` /__w/pybind11/pybind11/tests/test_smart_ptr.cpp:287:51: error: must specify at least one argument for '...' parameter of variadic macro [-Werror,-Wgnu-zero-variadic-macro-arguments] PYBIND11_DECLARE_HOLDER_TYPE(T, std::shared_ptr) ^ /__w/pybind11/pybind11/include/pybind11/cast.h:885:13: note: macro 'PYBIND11_DECLARE_HOLDER_TYPE' defined here ^ ``` --- tests/test_smart_ptr.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tests/test_smart_ptr.cpp b/tests/test_smart_ptr.cpp index 4ab43953f1..87595177c8 100644 --- a/tests/test_smart_ptr.cpp +++ b/tests/test_smart_ptr.cpp @@ -11,8 +11,9 @@ #include "object.h" #include "pybind11_tests.h" -// This breaks on PYBIND11_DECLARE_HOLDER_TYPE +// These break on PYBIND11_DECLARE_HOLDER_TYPE PYBIND11_WARNING_DISABLE_GCC("-Wpedantic") +PYBIND11_WARNING_DISABLE_CLANG("-Wgnu-zero-variadic-macro-arguments") namespace {