diff --git a/db/cql_type_parser.cc b/db/cql_type_parser.cc index 4677375904..738e9dd523 100644 --- a/db/cql_type_parser.cc +++ b/db/cql_type_parser.cc @@ -24,7 +24,7 @@ static ::shared_ptr parse_raw(const sstring& str) { }); } -data_type db::cql_type_parser::parse(const sstring& keyspace, const sstring& str, const data_dictionary::user_types_storage& uts) { +data_type db::cql_type_parser::parse(const sstring& keyspace, const sstring& str, const data_dictionary::user_types_metadata& utm) { static const thread_local std::unordered_map native_types = []{ std::unordered_map res; for (auto& nt : cql3::cql3_type::values()) { @@ -39,7 +39,11 @@ data_type db::cql_type_parser::parse(const sstring& keyspace, const sstring& str } auto raw = parse_raw(str); - return raw->prepare_internal(keyspace, uts.get(keyspace)).get_type(); + return raw->prepare_internal(keyspace, utm).get_type(); +} + +data_type db::cql_type_parser::parse(const sstring& keyspace, const sstring& str, const data_dictionary::user_types_storage& uts) { + return parse(keyspace, str, uts.get(keyspace)); } class db::cql_type_parser::raw_builder::impl { diff --git a/db/cql_type_parser.hh b/db/cql_type_parser.hh index f71eb60fcd..310c634182 100644 --- a/db/cql_type_parser.hh +++ b/db/cql_type_parser.hh @@ -22,11 +22,13 @@ class types_metadata; namespace data_dictionary { class keyspace_metadata; class user_types_storage; +class user_types_metadata; } namespace db { namespace cql_type_parser { +data_type parse(const sstring& keyspace, const sstring& type, const data_dictionary::user_types_metadata& utm); data_type parse(const sstring& keyspace, const sstring& type, const data_dictionary::user_types_storage& uts); class raw_builder {