kou commented on code in PR #47183:
URL: https://github.com/apache/arrow/pull/47183#discussion_r2229948189


##########
cpp/src/arrow/compare.cc:
##########
@@ -1550,7 +1551,31 @@ bool ArrayStatisticsValueTypeEquals(
         return v1 == v2;
       }
       // It is unreachable
-      DCHECK(false);
+      Unreachable("The types are different.");
+      return false;
+    };
+    return std::visit(EqualsVisitor, left.value(), right.value());
+  }
+}
+
+bool 
ArrayStatisticsNumericTypeEquals(std::optional<ArrayStatistics::NumericType> 
left,
+                                      
std::optional<ArrayStatistics::NumericType> right,
+                                      const EqualOptions& options) {

Review Comment:
   It seems that there is no function body difference between this and 
`ArrayStatisticsValueTypeEquals()`.
   
   Can we unify them as a template function?



-- 
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-unsubscr...@arrow.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to