#pragma once #include #include #include #include // NOLINTBEGIN(readability-convert-member-functions-to-static, cert-dcl58-cpp) template ErrorCodeType> struct std::formatter { constexpr auto parse(std::format_parse_context& ctx) { return ctx.begin(); } auto format(const ErrorCodeType& ec, auto& ctx) const { return std::format_to(ctx.out(), "{}", ec.what()); } }; template StringView> struct std::formatter { constexpr auto parse(std::format_parse_context& ctx) { return ctx.begin(); } auto format(const StringView& msg, auto& ctx) const { return std::format_to(ctx.out(), "{}", std::string_view(msg.data(), msg.size())); } }; template UrlBase> struct std::formatter { constexpr auto parse(std::format_parse_context& ctx) { return ctx.begin(); } auto format(const UrlBase& msg, auto& ctx) const { return std::format_to(ctx.out(), "{}", std::string_view(msg.buffer())); } }; template StringView> struct std::formatter { constexpr auto parse(std::format_parse_context& ctx) { return ctx.begin(); } auto format(const StringView& msg, auto& ctx) const { return std::format_to(ctx.out(), "{}", std::string_view(msg)); } }; // NOLINTEND(readability-convert-member-functions-to-static, cert-dcl58-cpp)