From 85527c4045db14f8092a26ae6726a4848b3be0d9 Mon Sep 17 00:00:00 2001 From: Peter Dimov Date: Wed, 31 May 2023 20:22:15 +0300 Subject: [PATCH] More -Wconversion fixes --- include/boost/core/bit.hpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/boost/core/bit.hpp b/include/boost/core/bit.hpp index 70376ff..68a39be 100644 --- a/include/boost/core/bit.hpp +++ b/include/boost/core/bit.hpp @@ -664,7 +664,7 @@ BOOST_CONSTEXPR T bit_floor( T x ) BOOST_NOEXCEPT { BOOST_STATIC_ASSERT( std::numeric_limits::is_integer && !std::numeric_limits::is_signed ); - return x == 0? 0: static_cast( T(1) << ( boost::core::bit_width( x ) - 1 ) ); + return x == 0? T(0): static_cast( T(1) << ( boost::core::bit_width( x ) - 1 ) ); } namespace detail