Pointless comparison warnings (#2971)

Co-authored-by: Federico Busato <fbusato@nvidia.com>
This commit is contained in:
Federico
2022-07-11 12:29:39 -07:00
committed by GitHub
co-authored by Federico Busato
parent 05be7a0764
commit 0db43cf7fe
2 changed files with 4 additions and 3 deletions
+1 -1
View File
@@ -405,7 +405,7 @@ template <typename T> auto convert_for_visit(T) -> monostate { return {}; }
template <typename Int>
FMT_CONSTEXPR auto to_unsigned(Int value) ->
typename std::make_unsigned<Int>::type {
FMT_ASSERT(value >= 0, "negative value");
FMT_ASSERT(std::is_unsigned<Int>::value || value >= 0, "negative value");
return static_cast<typename std::make_unsigned<Int>::type>(value);
}