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:
parent
51a0deca2c
commit
1245bf8e8a
@ -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())
|
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 <>
|
template <>
|
||||||
struct std::formatter<my_type> : std::formatter<std::string> {
|
struct std::formatter<my_type> : std::formatter<std::string> {
|
||||||
auto format(my_type my, format_context &ctx) const -> decltype(ctx.out()) {
|
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
|
#endif
|
||||||
|
Loading…
Reference in New Issue
Block a user