From b3fd0005dd67acf5208afc9b2b0dcc66fb6a0f17 Mon Sep 17 00:00:00 2001 From: Victor Zverovich Date: Fri, 3 Jan 2020 06:57:14 -1000 Subject: [PATCH] Suppress a bogus -Wdouble-promotion warning --- include/fmt/format.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/fmt/format.h b/include/fmt/format.h index eef086ee..df387422 100644 --- a/include/fmt/format.h +++ b/include/fmt/format.h @@ -1173,7 +1173,7 @@ int snprintf_float(T value, int precision, float_specs specs, buffer& buf); template T promote_float(T value) { return value; } -inline double promote_float(float value) { return value; } +inline double promote_float(float value) { return static_cast(value); } template FMT_CONSTEXPR void handle_int_type_spec(char spec, Handler&& handler) {