From 34972e452a654cfedfaf5a79a5a4f224e5def192 Mon Sep 17 00:00:00 2001 From: PHILO-HE Date: Sun, 11 Feb 2024 21:37:01 +0800 Subject: [PATCH] Fix compile issue --- velox/functions/prestosql/types/JsonType.cpp | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/velox/functions/prestosql/types/JsonType.cpp b/velox/functions/prestosql/types/JsonType.cpp index 9defbf9c7c98a..f159c99538cac 100644 --- a/velox/functions/prestosql/types/JsonType.cpp +++ b/velox/functions/prestosql/types/JsonType.cpp @@ -586,7 +586,7 @@ simdjson::error_code appendMapKey( const std::string_view& value, exec::GenericWriter& writer) { using T = typename TypeTraits::NativeType; - if constexpr (std::is_same_v) { + if constexpr (std::is_same_v || std::is_same_v) { return simdjson::INCORRECT_TYPE; } else { SIMDJSON_ASSIGN_OR_RAISE(writer.castTo(), fromString(value)); @@ -594,6 +594,13 @@ simdjson::error_code appendMapKey( } } +template <> +simdjson::error_code appendMapKey( + const std::string_view& value, + exec::GenericWriter& writer) { + VELOX_NYI("UNKNOWN type is not supported!"); +} + template <> simdjson::error_code appendMapKey( const std::string_view& value,