From 3db385f267f380b0290895e8689f46d94706363e Mon Sep 17 00:00:00 2001 From: Matt Borland Date: Thu, 8 Jan 2026 13:51:52 -0500 Subject: [PATCH 1/3] Don't automatically include {fmt} formatting --- include/boost/int128.hpp | 4 ---- 1 file changed, 4 deletions(-) diff --git a/include/boost/int128.hpp b/include/boost/int128.hpp index b32becc4..7e5e45c4 100644 --- a/include/boost/int128.hpp +++ b/include/boost/int128.hpp @@ -15,8 +15,4 @@ #include #include -#ifndef BOOST_INT128_BUILD_MODULE -#include -#endif - #endif // BOOST_INT128_HPP From 06137e7d76c1f16ee8e9f09acc2d1d2a7c6d71f4 Mon Sep 17 00:00:00 2001 From: Matt Borland Date: Thu, 8 Jan 2026 13:52:59 -0500 Subject: [PATCH 2/3] Improve format detection --- include/boost/int128/format.hpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/include/boost/int128/format.hpp b/include/boost/int128/format.hpp index c79141f3..ab6ff3f9 100644 --- a/include/boost/int128/format.hpp +++ b/include/boost/int128/format.hpp @@ -5,8 +5,7 @@ #ifndef BOOST_INT128_FORMAT_HPP #define BOOST_INT128_FORMAT_HPP -#if (__cplusplus >= 202002L || (defined(_MSVC_LANG) && _MSVC_LANG >= 202002L)) && \ -((defined(__GNUC__) && __GNUC__ >= 13) || (defined(__clang__) && __clang_major__ >= 18) || (defined(_MSC_VER) && _MSC_VER >= 1940)) +#if __has_include() && defined(__cpp_lib_format) && __cpp_lib_format >= 201907L && !defined(BOOST_DECIMAL_DISABLE_CLIB) #include #include From 9de176a4ce13e022b26e7317bd34fe8832376901 Mon Sep 17 00:00:00 2001 From: Matt Borland Date: Thu, 8 Jan 2026 13:55:44 -0500 Subject: [PATCH 3/3] Ignore new fmt warning --- include/boost/int128/fmt_format.hpp | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) diff --git a/include/boost/int128/fmt_format.hpp b/include/boost/int128/fmt_format.hpp index 1edad574..8612efdb 100644 --- a/include/boost/int128/fmt_format.hpp +++ b/include/boost/int128/fmt_format.hpp @@ -12,11 +12,22 @@ #include #include #include -#include -#include #include #include +#ifdef __GNUC__ +# pragma GCC diagnostic push +# pragma GCC diagnostic ignored "-Wconversion" +# pragma GCC diagnostic ignored "-Wsign-conversion" +#endif + +#include +#include + +#ifdef __GNUC__ +# pragma GCC diagnostic pop +#endif + #define BOOST_INT128_HAS_FMT_FORMAT namespace boost {