mirror of
https://github.com/fmtlib/fmt.git
synced 2024-12-26 09:28:21 +00:00
Fix compilation on pre C++11.
This commit is contained in:
parent
ccbe94189c
commit
100149eb58
@ -312,10 +312,12 @@ void Formatter::FormatString(
|
|||||||
char *out = 0;
|
char *out = 0;
|
||||||
if (spec.width > size) {
|
if (spec.width > size) {
|
||||||
out = GrowBuffer(spec.width);
|
out = GrowBuffer(spec.width);
|
||||||
if (spec.align == ALIGN_RIGHT)
|
if (spec.align == ALIGN_RIGHT) {
|
||||||
out = std::fill_n(out, spec.width - size, spec.fill);
|
std::fill_n(out, spec.width - size, spec.fill);
|
||||||
else
|
out += spec.width - size;
|
||||||
|
} else {
|
||||||
std::fill_n(out + size, spec.width - size, spec.fill);
|
std::fill_n(out + size, spec.width - size, spec.fill);
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
out = GrowBuffer(size);
|
out = GrowBuffer(size);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user