klion26 commented on code in PR #8196: URL: https://github.com/apache/arrow-rs/pull/8196#discussion_r2290442934
########## parquet-variant-compute/src/cast_to_variant.rs: ########## @@ -544,8 +530,41 @@ pub fn cast_to_variant(input: &dyn Array) -> Result<VariantArray, ArrowError> { Ok(builder.build()) } -/// Generic function to process run-end encoded arrays -fn process_run_end_encoded<R: RunEndIndexType>( +/// Convert union arrays +fn convert_union( + fields: &UnionFields, + input: &dyn Array, + builder: &mut VariantArrayBuilder, +) -> Result<(), ArrowError> { + let union_array = input.as_union(); + + // Convert each child array to variant arrays + let mut child_variant_arrays = HashMap::new(); + for (type_id, _) in fields.iter() { Review Comment: Do we need to merge the two passes into one? -- 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