diff --git a/uvio/coroutine/task.hpp b/uvio/coroutine/task.hpp index a025504..7312ea3 100644 --- a/uvio/coroutine/task.hpp +++ b/uvio/coroutine/task.hpp @@ -54,8 +54,9 @@ namespace detail { public: auto get_return_object() noexcept -> Task; - auto return_value(T &&value) noexcept { - value_ = std::move(value); + template + auto return_value(F &&value) noexcept { + value_ = std::forward(value); } auto result() const noexcept {