From 78f0bb9e24c90fd7c61fd85af37b3c5f0b58df4b Mon Sep 17 00:00:00 2001 From: NengLiu <1398775315@qq.com> Date: Fri, 9 Jul 2021 15:28:44 +0800 Subject: [PATCH] add type cast --- base/common/DateLUTImpl.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/base/common/DateLUTImpl.h b/base/common/DateLUTImpl.h index cb74243c472..dd4b097bf0d 100644 --- a/base/common/DateLUTImpl.h +++ b/base/common/DateLUTImpl.h @@ -1098,7 +1098,7 @@ public: inline NO_SANITIZE_UNDEFINED Time addWeeks(Time t, Int32 delta) const { - return addDays(t, delta * 7); + return addDays(t, static_cast(delta) * 7); } inline UInt8 saturateDayOfMonth(Int16 year, UInt8 month, UInt8 day_of_month) const @@ -1165,12 +1165,12 @@ public: inline Time NO_SANITIZE_UNDEFINED addQuarters(Time t, Int32 delta) const { - return addMonths(t, delta * 3); + return addMonths(t, static_cast(delta) * 3); } inline ExtendedDayNum addQuarters(ExtendedDayNum d, Int32 delta) const { - return addMonths(d, delta * 3); + return addMonths(d, static_cast(delta) * 3); } template