alamb commented on a change in pull request #750:
URL: https://github.com/apache/arrow-rs/pull/750#discussion_r705657918
##########
File path: arrow/src/record_batch.rs
##########
@@ -419,6 +419,18 @@ impl From<&StructArray> for RecordBatch {
}
}
+impl PartialEq for RecordBatch {
+ fn eq(&self, other: &RecordBatch) -> bool {
+ let batches_equal = true;
Review comment:
You might be able to express this in a more idomatic Rust with something
like
```rust
self
.columns()
.iter()
.zip(other.columns.iter())
.map(|(my_arr, other_arr)| my_arr == other.arr)
.all()
```
Or something similar.
--
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]