nevi-me opened a new pull request #389:
URL: https://github.com/apache/arrow-rs/pull/389
# Which issue does this PR close?
Corresponding issue might not yet exist, will check when finalising this PR
# Rationale for this change
`ArrayData::slice()` does not work for nested types, because only the
`ArrayData::buffers` are updated with the new offset and length. This has
caused a lot of issues in the past.
This blocks us from being able to implement `RecordBatch::slice()`, and has
led to creating #381 to sidestep this issue.
# What changes are included in this PR?
I propose a manual slice where we check if `ArrayData::child_data` is not
empty, and then propagate the offset and length down to them. The only trick is
with list and largelist, where we have to inspect the offset buffers to
determine what the new offset and length should be.
# Are there any user-facing changes?
No UFC
--
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.
For queries about this service, please contact Infrastructure at:
[email protected]