Ted-Jiang opened a new issue, #3655:
URL: https://github.com/apache/arrow-rs/issues/3655

   **Is your feature request related to a problem or challenge? Please describe 
what you are trying to do.**
   now  Array trait only support `as_any`
   
   
https://github.com/apache/arrow-rs/blob/9728c676b50b19c06643a23daba4aa4a1dc48055/arrow-array/src/array/mod.rs#L72-L106
   
   When I implementing  using copy on write to evaluate `col_x+1` binary_expr,
   I need cast `ArrayRef` to `PrimitiveArray` with ownership and with strong 
reference one😩 then pass to `unary_mut`.
   
   
https://github.com/apache/arrow-rs/blob/26ea71cefab55990ffb8197707f2a8518e41412d/arrow-arith/src/arity.rs#L59-L65
   
   So i decide using `downcast_mut` then use `mem::take()` get the ` array: 
PrimitiveArray<I>, `
   
   But there no  `as_any_mut` , so i try to add this func 🤔.
   Seems there already one in `ArrayBuilder`
   
https://github.com/apache/arrow-rs/blob/f0be9da82cbd76da3042b426daf6c424c9560d93/arrow-array/src/builder/mod.rs#L129
   **Describe the solution you'd like**
   <!--
   A clear and concise description of what you want to happen.
   -->
   
   **Describe alternatives you've considered**
   <!--
   A clear and concise description of any alternative solutions or features 
you've considered.
   -->
   
   **Additional context**
   <!--
   Add any other context or screenshots about the feature request 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]

Reply via email to