Taepper commented on code in PR #46926:
URL: https://github.com/apache/arrow/pull/46926#discussion_r3404743438


##########
cpp/src/arrow/compute/kernels/vector_select_k.cc:
##########
@@ -192,6 +307,25 @@ class ChunkedArraySelector : public TypeVisitor {
   VISIT_SORTABLE_PHYSICAL_TYPES(VISIT)
 #undef VISIT
 
+  template <typename InType>
+  int64_t ComputeNanCount() {
+    using ArrayType = typename TypeTraits<InType>::ArrayType;
+    if constexpr (has_null_like_values<typename ArrayType::TypeClass>()) {
+      int64_t nan_count = 0;
+      for (const auto& chunk : physical_chunks_) {
+        auto values = std::make_shared<ArrayType>(chunk->data());
+        int64_t length = values->length();
+        for (int64_t index = 0; index < length; ++index) {
+          if (std::isnan(values->GetView(index))) {

Review Comment:
   Superfluous as this function was removed when changing the calculation of 
`nan_count`



-- 
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