36template <std::derived_from<iceberg::util::Formattable> Derived>
37struct std::formatter<Derived> : std::formatter<std::string_view> {
38 template <
class FormatContext>
40 return std::formatter<string_view>::format(obj.
ToString(), ctx);
46 requires requires(
const T& t) {
47 { ToString(t) } -> std::convertible_to<std::string_view>;
49struct std::formatter<T> : std::formatter<std::string_view> {
50 template <
class FormatContext>
51 auto format(
const T& value, FormatContext& ctx)
const {
52 return std::formatter<std::string_view>::format(ToString(value), ctx);