This is an automated email from the ASF dual-hosted git repository.
yibocai pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/arrow.git
The following commit(s) were added to refs/heads/master by this push:
new 2ed54db ARROW-12325: [C++] [CI] Nightly gandiva build failing due to
failure of compiler to move return value
2ed54db is described below
commit 2ed54dbdb8d27b65def2db8d938240030986106c
Author: Weston Pace <[email protected]>
AuthorDate: Wed Apr 21 01:42:23 2021 +0000
ARROW-12325: [C++] [CI] Nightly gandiva build failing due to failure of
compiler to move return value
Gandiva build failure caused by failure of GCC 4.8.2 compiler to
automatically move return value.
Failed build: https://github.com/ursacomputing/crossbow/runs/2303374510
Godbolt showing I'm not crazy: https://gcc.godbolt.org/z/x138zevhE
Closes #9975 from westonpace/bugfix/ARROW-12325
Authored-by: Weston Pace <[email protected]>
Signed-off-by: Yibo Cai <[email protected]>
---
cpp/src/arrow/util/vector.h | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/cpp/src/arrow/util/vector.h b/cpp/src/arrow/util/vector.h
index 67401d4..b9f2e2a 100644
--- a/cpp/src/arrow/util/vector.h
+++ b/cpp/src/arrow/util/vector.h
@@ -92,7 +92,7 @@ Result<std::vector<To>> MaybeMapVector(Fn&& map, const
std::vector<From>& src) {
out.reserve(src.size());
ARROW_RETURN_NOT_OK(MaybeTransform(src.begin(), src.end(),
std::back_inserter(out),
std::forward<Fn>(map)));
- return out;
+ return std::move(out);
}
template <typename Fn, typename From,
@@ -130,7 +130,7 @@ Result<std::vector<T>>
UnwrapOrRaise(std::vector<Result<T>>&& results) {
}
out.push_back(it->MoveValueUnsafe());
}
- return out;
+ return std::move(out);
}
} // namespace internal