mirror of
https://github.com/fmtlib/fmt.git
synced 2025-11-29 22:00:09 +01:00
Path is not escaped twice in the debug mode (#3321)
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
This commit is contained in:
committed by
GitHub
parent
3daf33837c
commit
050293646f
@@ -77,6 +77,11 @@ inline void write_escaped_path<std::filesystem::path::value_type>(
|
||||
template <typename Char>
|
||||
struct formatter<std::filesystem::path, Char>
|
||||
: formatter<basic_string_view<Char>> {
|
||||
template <typename ParseContext> FMT_CONSTEXPR auto parse(ParseContext& ctx) {
|
||||
auto out = formatter<basic_string_view<Char>>::parse(ctx);
|
||||
this->set_debug_format(false);
|
||||
return out;
|
||||
}
|
||||
template <typename FormatContext>
|
||||
auto format(const std::filesystem::path& p, FormatContext& ctx) const ->
|
||||
typename FormatContext::iterator {
|
||||
|
||||
Reference in New Issue
Block a user