rluvaton commented on code in PR #7996:
URL: https://github.com/apache/arrow-rs/pull/7996#discussion_r2229632708


##########
arrow-row/src/lib.rs:
##########
@@ -518,12 +518,33 @@ impl Codec {
             }
             Codec::List(converter) => {
                 let values = match array.data_type() {
-                    DataType::List(_) => as_list_array(array).values(),
-                    DataType::LargeList(_) => 
as_large_list_array(array).values(),
-                    DataType::FixedSizeList(_, _) => 
as_fixed_size_list_array(array).values(),
+                    DataType::List(_) => {
+                        let list_array = as_list_array(array);
+                        let first_offset = list_array.offsets()[0] as usize;
+                        let last_offset =
+                            list_array.offsets()[list_array.offsets().len() - 
1] as usize;
+
+                        list_array
+                            .values()
+                            .slice(first_offset, last_offset - first_offset)

Review Comment:
   this can be changed to `get_values_sliced()` or something after we resolve:
   - #7992



-- 
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-unsubscr...@arrow.apache.org

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

Reply via email to