Merge pull request #10377 from Pokechu22/warning-fixes-jan-2022

Fix several compile warnings on GCC
This commit is contained in:
JosJuice 2022-02-18 21:05:42 +01:00 committed by GitHub
commit 35b436bd6b
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
12 changed files with 56 additions and 30 deletions

View file

@ -37,7 +37,7 @@ constexpr Dest SaturatingCast(T value)
{
static_assert(std::is_integral<Dest>());
constexpr Dest lo = std::numeric_limits<Dest>::lowest();
[[maybe_unused]] constexpr Dest lo = std::numeric_limits<Dest>::lowest();
constexpr Dest hi = std::numeric_limits<Dest>::max();
// T being a signed integer and Dest unsigned is a problematic case because the value will