viirya commented on a change in pull request #1469:
URL: https://github.com/apache/arrow-rs/pull/1469#discussion_r839296459
##########
File path: arrow/src/array/equal/utils.rs
##########
@@ -66,7 +66,14 @@ pub(super) fn equal_nulls(
#[inline]
pub(super) fn base_equal(lhs: &ArrayData, rhs: &ArrayData) -> bool {
- lhs.data_type() == rhs.data_type() && lhs.len() == rhs.len()
+ let equal_type = match (lhs.data_type(), rhs.data_type()) {
+ (DataType::Union(l_fields, l_mode), DataType::Union(r_fields, r_mode))
=> {
+ // Defer field datatype check to `union_equal`
Review comment:
Revised to compare lhs and rhs fields here.
--
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]