Fix compliation for -Wsign-compare

This commit is contained in:
libas zhang 2022-06-10 10:20:21 +08:00
parent 6a2b78a379
commit f04546b7d9

View file

@ -1390,7 +1390,7 @@ constexpr uint32_t CalculateNeeded(uint8_t tag) {
#if __cplusplus >= 201402L
constexpr bool VerifyCalculateNeeded() {
for (int i = 0; i < 1; i++) {
if (CalculateNeeded(i) != (char_table[i] >> 11) + 1) return false;
if (CalculateNeeded(i) != static_cast<uint32_t>((char_table[i] >> 11) + 1)) return false;
}
return true;
}