From 6cfef956057e09df4e1f0c610b6bd22d6ee0ef77 Mon Sep 17 00:00:00 2001 From: Peter Dimov Date: Tue, 28 Oct 2025 17:21:32 +0200 Subject: [PATCH] Disable more Clang warnings. Fixes #465. --- include/boost/test/detail/suppress_warnings.hpp | 4 ++++ include/boost/test/utils/runtime/env/fetch.hpp | 4 ++-- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/include/boost/test/detail/suppress_warnings.hpp b/include/boost/test/detail/suppress_warnings.hpp index 2145da5f91..df637b0751 100644 --- a/include/boost/test/detail/suppress_warnings.hpp +++ b/include/boost/test/detail/suppress_warnings.hpp @@ -30,6 +30,10 @@ # pragma clang diagnostic push # pragma clang diagnostic ignored "-Wvariadic-macros" # pragma clang diagnostic ignored "-Wmissing-declarations" +# pragma clang diagnostic ignored "-Wdeprecated-declarations" +# if BOOST_CLANG_VERSION >= 190000 +# pragma clang diagnostic ignored "-Wcast-function-type-mismatch" +# endif #endif #if defined(BOOST_GCC) && (BOOST_GCC >= 4 * 10000 + 6 * 100) diff --git a/include/boost/test/utils/runtime/env/fetch.hpp b/include/boost/test/utils/runtime/env/fetch.hpp index 97d54d4905..5a330bc56a 100644 --- a/include/boost/test/utils/runtime/env/fetch.hpp +++ b/include/boost/test/utils/runtime/env/fetch.hpp @@ -32,7 +32,7 @@ namespace env_detail { #ifndef UNDER_CE -#ifdef BOOST_MSVC +#ifdef _MSC_VER #pragma warning(push) #pragma warning(disable:4996) // getenv #endif @@ -46,7 +46,7 @@ sys_read_var( cstring var_name ) return std::make_pair( cstring(res), res != NULL ); } -#ifdef BOOST_MSVC +#ifdef _MSC_VER #pragma warning(pop) #endif