From 29ef7d31e4f475c3c33e3c8cf601d04a772a8897 Mon Sep 17 00:00:00 2001 From: Victor Zverovich Date: Sun, 23 Jun 2019 11:09:15 -0700 Subject: [PATCH] Fix a warning --- include/fmt/chrono.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/include/fmt/chrono.h b/include/fmt/chrono.h index 2d510783dca8..f47ff75345a8 100644 --- a/include/fmt/chrono.h +++ b/include/fmt/chrono.h @@ -433,8 +433,8 @@ template ::value)> inline std::chrono::duration get_milliseconds( std::chrono::duration d) { - return std::chrono::duration( - mod(d.count() * Period::num / Period::den * 1000, 1000)); + auto ms = mod(d.count() * Period::num / Period::den * 1000, 1000); + return std::chrono::duration(static_cast(ms)); } template