You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@arrow.apache.org by "sunchao (via GitHub)" <gi...@apache.org> on 2023/09/11 21:09:07 UTC
[GitHub] [arrow-rs] sunchao commented on a diff in pull request #4707: Add AnyDictionary Abstraction and Take ArrayRef in DictionaryArray::with_values
sunchao commented on code in PR #4707:
URL: https://github.com/apache/arrow-rs/pull/4707#discussion_r1322076511
##########
arrow-arith/src/arity.rs:
##########
@@ -105,10 +105,11 @@ where
let dict_values = array.values().as_any().downcast_ref().unwrap();
let values = try_unary::<T, F, T>(dict_values, op)?;
- Ok(Arc::new(array.with_values(&values)))
+ Ok(Arc::new(array.with_values(Arc::new(values))))
}
/// Applies an infallible unary function to an array with primitive values.
+#[deprecated(note = "Use arrow_array::AnyDictionaryArray")]
Review Comment:
@tustvold @alamb saw this when upgrading to the latest DF 31.0.0, and I think this deprecation note doesn't look very helpful: should users implement the functionalities of `unary_dyn` by themselves using things like `as_any_dictionary_opt`? shall we just change the implementation of `unary_dyn` using the new APIs instead?
--
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-unsubscribe@arrow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org