From 930c381bb1348011ad6e531df61d0bd1b832cfe3 Mon Sep 17 00:00:00 2001 From: Yibo Cai Date: Tue, 20 Apr 2021 10:01:09 -0400 Subject: [PATCH] ARROW-12475: [C++] Fix 'warn_unused_result' warning Closes #10107 from cyb70289/12475-clang-warning Authored-by: Yibo Cai Signed-off-by: David Li --- cpp/src/arrow/util/thread_pool_benchmark.cc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/cpp/src/arrow/util/thread_pool_benchmark.cc b/cpp/src/arrow/util/thread_pool_benchmark.cc index 054d616d035e3..b02ca9bb54b95 100644 --- a/cpp/src/arrow/util/thread_pool_benchmark.cc +++ b/cpp/src/arrow/util/thread_pool_benchmark.cc @@ -110,10 +110,10 @@ static void RunInSerialExecutor(benchmark::State& state) { // NOLINT non-const Workload workload(workload_size); for (auto _ : state) { - SerialExecutor::RunInSerialExecutor( + ABORT_NOT_OK(SerialExecutor::RunInSerialExecutor( [&](internal::Executor* executor) { return DeferNotOk(executor->Submit(std::ref(workload))); - }); + })); } state.SetItemsProcessed(state.iterations());