crimson/os: capture structured binding labels with new variable

structured binding does not define variables. unlike GCC, Clang does
not allow this.

Signed-off-by: Kefu Chai <kchai@redhat.com>
This commit is contained in:
Kefu Chai 2021-03-02 19:46:40 +08:00
parent cec783344e
commit c951ec3eb2

View File

@ -209,7 +209,8 @@ OMapInnerNode::list(
[=, &start](auto &biter, auto &eiter, auto &ret) {
auto &[complete, result] = ret;
return crimson::do_until(
[&, max_result_size, oc, this]() -> list_ertr::future<bool> {
[&, &complete=complete, &result=result, max_result_size, oc, this]()
-> list_ertr::future<bool> {
if (biter == eiter || result.size() == max_result_size) {
complete = biter == eiter;
return list_ertr::make_ready_future<bool>(true);