From 5874652967f44eea26ac5e2aad4759fe14c13e7e Mon Sep 17 00:00:00 2001 From: Kefu Chai Date: Thu, 30 Nov 2023 12:12:22 +0800 Subject: [PATCH] cql3: define format_as() for formatting cql3::cql3_type in the same spirit of 724a6e26, format_as() is defined for cql3::cql3_type. despite that this is not used yet by fmt v9, where we still have FMT_DEPRECATED_OSTREAM, this prepares us for fmt v10. Refs #13245 Signed-off-by: Kefu Chai Closes scylladb/scylladb#16232 --- cql3/cql3_type.hh | 3 +++ 1 file changed, 3 insertions(+) diff --git a/cql3/cql3_type.hh b/cql3/cql3_type.hh index cfa116ea7d..c00dc6e514 100644 --- a/cql3/cql3_type.hh +++ b/cql3/cql3_type.hh @@ -77,6 +77,9 @@ private: class raw_collection; class raw_ut; class raw_tuple; + friend std::string_view format_as(const cql3_type& t) { + return t.to_string(); + } friend std::ostream& operator<<(std::ostream& os, const cql3_type& t) { return os << t.to_string(); }