mirror of
https://github.com/fmtlib/fmt.git
synced 2024-12-26 00:21:13 +00:00
Fix NonZero
This commit is contained in:
parent
885d1a1c64
commit
d618f8baac
2
format.h
2
format.h
@ -704,7 +704,7 @@ void format_windows_error(fmt::Writer &out, int error_code,
|
||||
// allocating an array of 0 size.
|
||||
template <unsigned N>
|
||||
struct NonZero {
|
||||
enum { VALUE = N > 0 ? N : 0 };
|
||||
enum { VALUE = N > 0 ? N : 1 };
|
||||
};
|
||||
|
||||
// A formatting argument. It is a POD type to allow storage in
|
||||
|
Loading…
Reference in New Issue
Block a user