mirror of
https://github.com/gabime/spdlog.git
synced 2025-09-28 17:19:34 +08:00
add explicit mt:: and std:: to avoid ambiguous call when both std::format_to and mt::format_to are present (#3259)
This commit is contained in:
@@ -303,7 +303,7 @@ struct fmt::formatter<my_type> : fmt::formatter<std::string>
|
||||
{
|
||||
auto format(my_type my, format_context &ctx) const -> decltype(ctx.out())
|
||||
{
|
||||
return format_to(ctx.out(), "[my_type i={}]", my.i);
|
||||
return fmt::format_to(ctx.out(), "[my_type i={}]", my.i);
|
||||
}
|
||||
};
|
||||
|
||||
|
@@ -281,7 +281,7 @@ struct fmt::formatter<my_type> : fmt::formatter<std::string> {
|
||||
template <>
|
||||
struct std::formatter<my_type> : std::formatter<std::string> {
|
||||
auto format(my_type my, format_context &ctx) const -> decltype(ctx.out()) {
|
||||
return format_to(ctx.out(), "[my_type i={}]", my.i);
|
||||
return std::format_to(ctx.out(), "[my_type i={}]", my.i);
|
||||
}
|
||||
};
|
||||
#endif
|
||||
|
Reference in New Issue
Block a user