MathUtil: Mark lo in SaturatingCast as [[maybe_unused]]

It's unused in the case that T is unsigned and dest is signed (e.g. SaturatingCast<int, size_t> which appears SetIsoPaths in MainSettings.cpp)
This commit is contained in:
Pokechu22 2022-01-16 23:32:27 -08:00
parent a6d516dc94
commit 15f80f7234
1 changed files with 1 additions and 1 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