You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In file included from <source>:1:
In file included from /opt/compiler-explorer/libs/fmt/trunk/include/fmt/format.h:54:
/opt/compiler-explorer/libs/fmt/trunk/include/fmt/core.h:541:56: error: implicit instantiation of undefined template 'fmt::v5::formatter<A::Y, char, void>'
typename Context::template formatter_type<T>::type f;
^
/opt/compiler-explorer/libs/fmt/trunk/include/fmt/core.h:527:22: note: in instantiation of function template specialization 'fmt::v5::internal::value<fmt::v5::basic_format_context<std::back_insert_iterator<fmt::v5::internal::basic_buffer<char> >, char> >::format_custom_arg<A::Y>' requested here
custom.format = &format_custom_arg<T>;
^
/opt/compiler-explorer/libs/fmt/trunk/include/fmt/core.h:553:45: note: in instantiation of function template specialization 'fmt::v5::internal::value<fmt::v5::basic_format_context<std::back_insert_iterator<fmt::v5::internal::basic_buffer<char> >, char> >::value<A::Y>' requested here
FMT_CONSTEXPR typed_value(const T &val) : value<Context>(val) {}
^
/opt/compiler-explorer/libs/fmt/trunk/include/fmt/core.h:960:10: note: in instantiation of function template specialization 'fmt::v5::internal::make_value<fmt::v5::basic_format_context<std::back_insert_iterator<fmt::v5::internal::basic_buffer<char> >, char>, A::Y, char>' requested here
return make_value<Context>(value);
^
/opt/compiler-explorer/libs/fmt/trunk/include/fmt/core.h:1013:23: note: in instantiation of function template specialization 'fmt::v5::internal::make_arg<true, fmt::v5::basic_format_context<std::back_insert_iterator<fmt::v5::internal::basic_buffer<char> >, char>, A::Y>' requested here
: data_{internal::make_arg<IS_PACKED, Context>(args)...} {}
^
/opt/compiler-explorer/libs/fmt/trunk/include/fmt/core.h:1262:45: note: in instantiation of member function 'fmt::v5::format_arg_store<fmt::v5::basic_format_context<std::back_insert_iterator<fmt::v5::internal::basic_buffer<char> >, char>, A::Y>::format_arg_store' requested here
format_arg_store<format_context, Args...> as{args...};
^
<source>:29:19: note: in instantiation of function template specialization 'fmt::v5::format<A::Y>' requested here
auto s = fmt::format("{}", A::Y{});
^
/opt/compiler-explorer/libs/fmt/trunk/include/fmt/core.h:315:8: note: template is declared here
struct formatter;
The text was updated successfully, but these errors were encountered:
Hi,
What is the correct way to provide the formatter for a derived class that uses the formatter of the base class? Something like this doesn't work:
Compilation error:
The text was updated successfully, but these errors were encountered: