From 2816efe188d5f335c4713ab68145d1b9df59452e Mon Sep 17 00:00:00 2001 From: Jeffrey Walton Date: Sat, 20 Jan 2018 19:37:58 -0500 Subject: [PATCH] Clear GCC -Wstrict-overflow warning This is a false positive when "T=int" or "T=long". "value" is reduced by division so it converges to 0. It is never less than 0. --- misc.h | 1 + 1 file changed, 1 insertion(+) diff --git a/misc.h b/misc.h index cf265ddd..9bfa586e 100644 --- a/misc.h +++ b/misc.h @@ -524,6 +524,7 @@ template inline const T& STDMAX(const T& a, const T& b) #if CRYPTOPP_GCC_DIAGNOSTIC_AVAILABLE # pragma GCC diagnostic push # pragma GCC diagnostic ignored "-Wsign-compare" +# pragma GCC diagnostic ignored "-Wstrict-overflow" # if (CRYPTOPP_LLVM_CLANG_VERSION >= 20800) || (CRYPTOPP_APPLE_CLANG_VERSION >= 30000) # pragma GCC diagnostic ignored "-Wtautological-compare" # elif (CRYPTOPP_GCC_VERSION >= 40300)