mirror of
https://github.com/fmtlib/fmt.git
synced 2024-11-26 20:20:04 +00:00
Fix conversion warning in filesystem::path formatter (#3806)
* Fix conversion warning in filesystem::path formatter Use template character type to eliminate MSVC conversion warning when formatting a wide chararacter path: fmt\std.h(140,49): warning C4244: '=': conversion from 'const Char' to 'char', possible loss of data * Review: use to_ascii instead --------- Co-authored-by: Hans-Martin B. Jensen <haje@eposaudio.com>
This commit is contained in:
parent
1b55d10305
commit
7c163acfda
@ -137,7 +137,7 @@ template <typename Char> struct formatter<std::filesystem::path, Char> {
|
||||
debug_ = true;
|
||||
++it;
|
||||
}
|
||||
if (it != end && (*it == 'g')) path_type_ = *it++;
|
||||
if (it != end && (*it == 'g')) path_type_ = detail::to_ascii(*it++);
|
||||
return it;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user