From dc09e1a130bce1b3584f7de06693b7c6f2228dea Mon Sep 17 00:00:00 2001 From: Radoslaw Zarzynski Date: Sun, 29 Sep 2019 15:02:06 +0200 Subject: [PATCH] crimson: drop as_plain_future() from errorated futures. Signed-off-by: Radoslaw Zarzynski --- src/crimson/common/errorator.h | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/src/crimson/common/errorator.h b/src/crimson/common/errorator.h index 1305bb48afc..a9d9718f440 100644 --- a/src/crimson/common/errorator.h +++ b/src/crimson/common/errorator.h @@ -374,7 +374,7 @@ struct errorator { typename ErroratedFuture::errorator_type; static_assert(dest_errorator_t::template contains_once_v, "conversion is possible to more-or-eq errorated future!"); - return std::move(*this).as_plain_future(); + return static_cast(*this); } // initialize future as failed without throwing. `make_exception_future()` @@ -506,9 +506,6 @@ struct errorator { template friend class errorator; - base_t&& as_plain_future() && { - return std::move(*this); - } }; // the visitor that forwards handling of all errors to next continuation @@ -605,7 +602,7 @@ private: } template static decltype(auto) plainify(Arg&& arg) { - return std::forward(arg).as_plain_future(); + return std::forward(arg); } template > -- 2.39.5