MCPcopy Create free account
hub / github.com/apache/arrow / operator()

Method operator()

cpp/src/arrow/util/future.h:518–530  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

516 "OnSuccess' argument should not be a Result");
517
518 void operator()(const Result<T>& result) && {
519 detail::ContinueFuture continue_future;
520 if (ARROW_PREDICT_TRUE(result.ok())) {
521 // move on_failure to a(n immediately destroyed) temporary to free its resources
522 ARROW_UNUSED(OnFailure(std::move(on_failure)));
523 continue_future.IgnoringArgsIf(
524 detail::if_has_no_args<OnSuccess, std::true_type, std::false_type>{},
525 std::move(next), std::move(on_success), result.ValueOrDie());
526 } else {
527 ARROW_UNUSED(OnSuccess(std::move(on_success)));
528 continue_future(std::move(next), std::move(on_failure), result.status());
529 }
530 }
531
532 OnSuccess on_success;
533 OnFailure on_failure;

Callers

nothing calls this directly

Calls 4

IgnoringArgsIfMethod · 0.80
ValueOrDieMethod · 0.80
okMethod · 0.45
statusMethod · 0.45

Tested by

no test coverage detected