mirror of
https://github.com/fmtlib/fmt.git
synced 2024-11-19 11:14:41 +00:00
Fix a warning (#2233)
This commit is contained in:
parent
52bd62c72f
commit
6271406233
@ -2400,7 +2400,7 @@ FMT_CONSTEXPR int parse_nonnegative_int(const Char*& begin, const Char* end,
|
||||
FMT_ASSERT(begin != end && '0' <= *begin && *begin <= '9', "");
|
||||
unsigned value = 0;
|
||||
// Convert to unsigned to prevent a warning.
|
||||
constexpr unsigned max_int = max_value<int>();
|
||||
const unsigned max_int = to_unsigned(max_value<int>());
|
||||
unsigned big = max_int / 10;
|
||||
do {
|
||||
// Check for overflow.
|
||||
|
Loading…
Reference in New Issue
Block a user