The enable_if argument is 3rd.
This commit is contained in:
parent
8b89454994
commit
e00b508ed1
@ -278,7 +278,7 @@ You can also write a formatter for a hierarchy of classes::
|
|||||||
};
|
};
|
||||||
|
|
||||||
template <typename T>
|
template <typename T>
|
||||||
struct fmt::formatter<T, std::enable_if_t<std::is_base_of<A, T>::value, char>> :
|
struct fmt::formatter<T, char, std::enable_if_t<std::is_base_of<A, T>::value>> :
|
||||||
fmt::formatter<std::string> {
|
fmt::formatter<std::string> {
|
||||||
template <typename FormatCtx>
|
template <typename FormatCtx>
|
||||||
auto format(const A& a, FormatCtx& ctx) {
|
auto format(const A& a, FormatCtx& ctx) {
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user