lidavidm commented on a change in pull request #12136:
URL: https://github.com/apache/arrow/pull/12136#discussion_r789714967
##########
File path: cpp/src/arrow/compute/kernels/scalar_arithmetic.cc
##########
@@ -1693,7 +1692,9 @@ struct ArithmeticFunction : ScalarFunction {
if (values->size() == 2) {
ReplaceNullWithOtherType(values);
- if (auto type = CommonNumeric(*values)) {
+ if (auto type = CommonTemporal(values->data(), values->size())) {
Review comment:
Now that I think about it, this is kind of weird to use CommonTemporal
since there isn't actually a "common" type between date32 and duration (for
instance) and what we actually care about here is the common unit - maybe it's
worth splitting that off separately? Since future/other uses of CommonTemporal
might be 'surprised' to find that `CommonTemporal(date, duration) => date`
instead of nullptr.
--
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]