zanmato1984 commented on code in PR #39234:
URL: https://github.com/apache/arrow/pull/39234#discussion_r1434391548
##########
cpp/src/arrow/compute/light_array.cc:
##########
@@ -395,8 +395,12 @@ int ExecBatchBuilder::NumRowsToSkip(const
std::shared_ptr<ArrayData>& column,
--num_rows_left;
int row_id_removed = row_ids[num_rows_left];
const uint32_t* offsets =
- reinterpret_cast<const uint32_t*>(column->buffers[1]->data());
+ reinterpret_cast<const uint32_t*>(column->buffers[1]->data()) +
column->offset;
num_bytes_skipped += offsets[row_id_removed + 1] -
offsets[row_id_removed];
+ // Skip consecutive rows with the same id
Review Comment:
> Would you like to update the docstring for `NumRowsToSkip` to make the
semantics more understandable?
I updated the docstring in the header, though I don't think I've made it
more understandable :-(
Please let me know if you found any specific peace of the docstring is not
clear enough. I appreciate that.
--
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]