You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@arrow.apache.org by "askoa (via GitHub)" <gi...@apache.org> on 2023/03/08 23:33:33 UTC

[GitHub] [arrow-rs] askoa commented on a diff in pull request #3818: Add ArrayDataLayout (#1799)

askoa commented on code in PR #3818:
URL: https://github.com/apache/arrow-rs/pull/3818#discussion_r1130200079


##########
arrow-data/src/data/run.rs:
##########
@@ -116,22 +170,67 @@ impl<E: RunEnd> RunArrayData<E> {
     /// # Safety
     ///
     /// - `data_type` must be valid for this layout
-    /// - `run_ends` must contain monotonically increasing, positive values `<= child.len()`
+    /// - `run_ends` must contain monotonically increasing, positive values `<= len`
+    /// - `run_ends.len() == child.len()`

Review Comment:
   Not clear what `child` refers to. The variable `child` in below function is built using scalar buffer and its length will not be equal to `run_ends.len()`.
   Also, there are two children. So it'll be clear to mention which child is being referred in the comment. 



-- 
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: github-unsubscribe@arrow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org