mirror of
https://github.com/gabime/spdlog.git
synced 2025-09-29 01:29:35 +08:00
-mpattern_formatter small change in pad3
This commit is contained in:
@@ -72,18 +72,19 @@ inline void append_and_pad3(int n, fmt::memory_buffer &dest)
|
||||
if (n > 9) // 10-99
|
||||
{
|
||||
dest.push_back('0');
|
||||
append_int(n, dest);
|
||||
return;
|
||||
}
|
||||
if (n >= 0)
|
||||
else if (n >= 0)
|
||||
{
|
||||
dest.push_back('0');
|
||||
dest.push_back('0');
|
||||
append_int(n, dest);
|
||||
return;
|
||||
}
|
||||
// negatives (unlikely, but just in case let fmt deal with it)
|
||||
fmt::format_to(dest, "{:03}", n);
|
||||
else
|
||||
{
|
||||
fmt::format_to(dest, "{:03}", n);
|
||||
return;
|
||||
}
|
||||
append_int(n, dest);
|
||||
}
|
||||
|
||||
void append_and_pad6(int n, fmt::memory_buffer &dest)
|
||||
|
Reference in New Issue
Block a user