mirror of
https://github.com/ToruNiina/toml11.git
synced 2025-09-18 02:08:09 +08:00
fix: pass empty filename to format_location
not to skip the first empty line
This commit is contained in:
@@ -107,10 +107,8 @@ std::string format_location(
|
|||||||
{
|
{
|
||||||
const auto lnw = detail::line_width(loc, msg, tail...);
|
const auto lnw = detail::line_width(loc, msg, tail...);
|
||||||
|
|
||||||
std::ostringstream oss;
|
const std::string f(""); // at the 1st iteration, no prev_filename is given
|
||||||
detail::format_filename(oss, loc);
|
return detail::format_location_rec(lnw, f, loc, msg, tail...);
|
||||||
|
|
||||||
return oss.str() + detail::format_location_rec(lnw, loc.file_name(), loc, msg, tail...);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
} // toml
|
} // toml
|
||||||
|
Reference in New Issue
Block a user