tustvold commented on code in PR #4364:
URL: https://github.com/apache/arrow-rs/pull/4364#discussion_r1218317323
##########
arrow-json/src/writer.rs:
##########
@@ -202,6 +203,15 @@ pub fn array_to_json_array(array: &ArrayRef) ->
Result<Vec<Value>, ArrowError> {
let jsonmaps = struct_array_to_jsonmap_array(array.as_struct())?;
Ok(jsonmaps.into_iter().map(Value::Object).collect())
}
+ DataType::Map(_, _) => as_map_array(array)
+ .iter()
+ .map(|maybe_value| match maybe_value {
+ Some(v) => Ok(Value::Array(array_to_json_array(
Review Comment:
We should probably change array_to_json_array to take `&dyn Array` to avoid
the needless Arc-wrapping
--
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]