Dandandan commented on a change in pull request #8938:
URL: https://github.com/apache/arrow/pull/8938#discussion_r544585525
##########
File path: rust/arrow/src/json/reader.rs
##########
@@ -1175,8 +1239,103 @@ impl Decoder {
}
Ok(Arc::new(builder.finish()) as ArrayRef)
}
+
+ /// Read the primitive list's values into ArrayData
+ fn read_primitive_list_values<T>(&self, rows: &[Value]) -> ArrayDataRef
+ where
+ T: ArrowPrimitiveType + ArrowNumericType,
+ T::Native: num::NumCast,
+ {
+ let values = rows
+ .iter()
+ .filter_map(|row| {
Review comment:
You could simplify the filter_map + flatten with flat_map + empty iter
instead
----------------------------------------------------------------
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]