MCPcopy Create free account
hub / github.com/apache/arrow / Call

Method Call

cpp/src/arrow/compute/kernels/base_arithmetic_internal.h:402–414  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

400struct DivideChecked {
401 template <typename T, typename Arg0, typename Arg1>
402 static enable_if_integer_value<T> Call(KernelContext*, Arg0 left, Arg1 right,
403 Status* st) {
404 static_assert(std::is_same<T, Arg0>::value && std::is_same<T, Arg1>::value, "");
405 T result;
406 if (ARROW_PREDICT_FALSE(DivideWithOverflow(left, right, &result))) {
407 if (right == 0) {
408 *st = Status::Invalid("divide by zero");
409 } else {
410 *st = Status::Invalid("overflow");
411 }
412 }
413 return result;
414 }
415
416 template <typename T, typename Arg0, typename Arg1>
417 static enable_if_floating_value<T> Call(KernelContext*, Arg0 left, Arg1 right,

Callers

nothing calls this directly

Calls 1

InvalidFunction · 0.50

Tested by

no test coverage detected