| 54 | }; |
| 55 | |
| 56 | static std::unique_ptr<FunctionBindData> bindFunc(const ScalarBindFuncInput& input) { |
| 57 | DASSERT(input.arguments.size() == 3); |
| 58 | std::vector<LogicalType> paramTypes; |
| 59 | auto& arg0Type = input.arguments[0]->getDataType(); |
| 60 | LogicalType resultType; |
| 61 | switch (arg0Type.getLogicalTypeID()) { |
| 62 | case LogicalTypeID::ANY: { |
| 63 | paramTypes.push_back(LogicalType::STRING()); |
| 64 | resultType = LogicalType::STRING(); |
| 65 | } break; |
| 66 | case LogicalTypeID::ARRAY: { |
| 67 | paramTypes.push_back(arg0Type.copy()); |
| 68 | resultType = LogicalType::LIST(ArrayType::getChildType(arg0Type).copy()); |
| 69 | } break; |
| 70 | default: { |
| 71 | paramTypes.push_back(arg0Type.copy()); |
| 72 | resultType = arg0Type.copy(); |
| 73 | } |
| 74 | } |
| 75 | paramTypes.push_back(LogicalType(input.definition->parameterTypeIDs[1])); |
| 76 | paramTypes.push_back(LogicalType(input.definition->parameterTypeIDs[2])); |
| 77 | return std::make_unique<FunctionBindData>(std::move(paramTypes), std::move(resultType)); |
| 78 | } |
| 79 | |
| 80 | function_set ListSliceFunction::getFunctionSet() { |
| 81 | function_set result; |
nothing calls this directly
no test coverage detected