davidhewitt commented on code in PR #7519:
URL: https://github.com/apache/arrow-rs/pull/7519#discussion_r2126484573
##########
arrow-select/src/dictionary.rs:
##########
@@ -120,7 +121,12 @@ pub fn should_merge_dictionary_values<K:
ArrowDictionaryKeyType>(
LargeUtf8 => Box::new(bytes_ptr_eq::<LargeUtf8Type>),
Binary => Box::new(bytes_ptr_eq::<BinaryType>),
LargeBinary => Box::new(bytes_ptr_eq::<LargeBinaryType>),
- _ => return false,
+ dt => {
+ if !dt.is_primitive() {
+ return false;
+ }
+ Box::new(|a, b| a.to_data().ptr_eq(&b.to_data()))
Review Comment:
Slight nit, I don't think the boxing is necessary for any of these match arms
```rust
// above, change to `let ptr_eq: PtrEq` without the box and adjust the other
arms too
|a, b| a.to_data().ptr_eq(&b.to_data())
```
--
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]