Skip to content

Commit

Permalink
chore: keep value in keepThis
Browse files Browse the repository at this point in the history
  • Loading branch information
OEOTYAN committed Sep 15, 2024
1 parent 495317a commit 791963c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/ll/api/coro/CoroTask.h
Original file line number Diff line number Diff line change
Expand Up @@ -122,8 +122,8 @@ inline auto collectAll(CoroTask<Ts>... tasks)
}
template <class F, class... Args>
requires(traits::is_specialization_of_v<std::invoke_result_t<F, Args...>, CoroTask>)
auto keepThis(F&& f, Args&&... args) -> std::invoke_result_t<F, Args...> {
co_return co_await std::invoke(std::forward<F>(f), std::forward<Args>(args)...);
auto keepThis(F f, Args... args) -> std::invoke_result_t<F, Args...> {
co_return co_await std::invoke(f, std::move(args)...);
}

} // namespace ll::coro

0 comments on commit 791963c

Please sign in to comment.