bjchambers commented on issue #510: URL: https://github.com/apache/arrow-rs/issues/510#issuecomment-871381407
I can do that. Although there are cases where nullif could return a reference. For instance if the boolean column is all false and non-null. I guess maybe the Arc doesn't provide large wins of the underlying data is Arc'ed. I ran into a problem with equality of sliced struct arrays. I'll post a draft PR and maybe file another issue. On Tue, Jun 29, 2021, 11:38 PM Jorge Leitao ***@***.***> wrote: > Yep, that aligns well with the other kernels, and it is in general > preferable as it avoids others having to do the same. > > I would use &dyn Array instead of ArrayRef as its argument, since there > is no need to require Arcing an array for using the kernel. With this > signature, we can write > > let array: PrimtiveArray<i32> = ...;let array = nullif(&array)?; > > instead of > > let array: PrimtiveArray<i32> = ...;let array = nullif(&Arc::new(array))?; > > — > You are receiving this because you authored the thread. > Reply to this email directly, view it on GitHub > <https://github.com/apache/arrow-rs/issues/510#issuecomment-871136975>, > or unsubscribe > <https://github.com/notifications/unsubscribe-auth/AAAIY6ECTXUDNHCOYERT5NTTVK3VDANCNFSM47RGUOQQ> > . > -- 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]
