since fmt v9, fmt::formatter<> is not specialized for the types with
operator<<(ostream&, ...) anymore. so we need to specialize it manually.
in this change, fmt::formatter<rgw_obj_key> is defined so the tree can
compile with fmt v9.
Signed-off-by: Kefu Chai <tchaikov@gmail.com>
return out << o.to_str();
}
+template<> struct fmt::formatter<rgw_obj_key> : fmt::formatter<std::string_view> {
+ template <typename FormatContext>
+ auto format(const rgw_obj_key& key, FormatContext& ctx) const {
+ return formatter<std::string_view>::format(key.to_str(), ctx);
+ }
+};
+
struct rgw_raw_obj {
rgw_pool pool;
std::string oid;