]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
crimson/os: capture structured binding labels with new variable
authorKefu Chai <kchai@redhat.com>
Tue, 2 Mar 2021 11:46:40 +0000 (19:46 +0800)
committerKefu Chai <kchai@redhat.com>
Tue, 2 Mar 2021 11:54:14 +0000 (19:54 +0800)
structured binding does not define variables. unlike GCC, Clang does
not allow this.

Signed-off-by: Kefu Chai <kchai@redhat.com>
src/crimson/os/seastore/omap_manager/btree/omap_btree_node_impl.cc

index acade8e43a3fe1d04817dcfe0b31d9a7a2f449e3..e71260ffd8c0999ae72c2ecbbd090e109b7921fb 100644 (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);