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 >