Makes format string argument positional.
| 22 | |
| 23 | // Makes format string argument positional. |
| 24 | static auto make_positional(fmt::string_view format) -> std::string { |
| 25 | std::string s(format.data(), format.size()); |
| 26 | s.replace(s.find('%'), 1, "%1$"); |
| 27 | return s; |
| 28 | } |
| 29 | |
| 30 | // A wrapper around fmt::sprintf to workaround bogus warnings about invalid |
| 31 | // format strings in MSVC. |