mirror of
https://github.com/ToruNiina/toml11.git
synced 2024-11-09 22:30:07 +00:00
fix: reset stream width before printing
without this, the first line of the serialized result becomes too wide
This commit is contained in:
parent
d7b8c3c78f
commit
2dd0a78c52
@ -501,7 +501,7 @@ operator<<(std::basic_ostream<charT, traits>& os, const value& v)
|
||||
// get status of std::setw().
|
||||
const std::size_t w = os.width();
|
||||
const int fprec = os.precision();
|
||||
|
||||
os.width(0);
|
||||
// the root object can't be an inline table. so pass `false`.
|
||||
os << visit(serializer(w, fprec, false), v);
|
||||
return os;
|
||||
|
Loading…
Reference in New Issue
Block a user