lidavidm commented on a change in pull request #11159:
URL: https://github.com/apache/arrow/pull/11159#discussion_r710194964
##########
File path: cpp/src/arrow/compute/kernels/codegen_internal.cc
##########
@@ -194,6 +194,11 @@ Result<ValueDescr> FirstType(KernelContext*, const
std::vector<ValueDescr>& desc
return result;
}
+Result<ValueDescr> ListValuesType(KernelContext*, const
std::vector<ValueDescr>& args) {
+ const auto& list_type = checked_cast<const BaseListType&>(*args[0].type);
+ return ValueDescr::Array(list_type.value_type());
Review comment:
You can see it above:
https://github.com/apache/arrow/blob/954ca3e0962a45f588c1ab19fd100c728b3d7c42/cpp/src/arrow/compute/kernels/codegen_internal.cc#L191-L195
It would be something like this:
```cpp
return ValueDescr(list_type.value_type(), GetBroadcastShape(args));
```
Note you may want to then update this kernel to support scalar inputs. (If
you want to use CheckScalar for testing, you'll need to.)
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]