viirya commented on a change in pull request #1407:
URL: https://github.com/apache/arrow-rs/pull/1407#discussion_r822095510



##########
File path: arrow/src/ffi.rs
##########
@@ -508,14 +541,20 @@ pub trait ArrowArrayRef {
         let buffers = self.buffers()?;
         let null_bit_buffer = self.null_bit_buffer();
 
-        let child_data = (0..self.array().n_children as usize)
+        let mut child_data: Vec<ArrayData> = (0..self.array().n_children as 
usize)
             .map(|i| {
                 let child = self.child(i);
                 child.to_data()
             })
             .map(|d| d.unwrap())
             .collect();
 
+        if let Some(d) = self.dictionary() {
+            // For dictionary type there should only be a single child, so we 
don't need to worry if

Review comment:
       Should we add assert for 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]


Reply via email to