Skip to content

Commit

Permalink
ad static_assert for async_construct to have a set_value(handle) comp…
Browse files Browse the repository at this point in the history
…letion
  • Loading branch information
kirkshoop committed May 25, 2024
1 parent 55dc3de commit 2909810
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions include/exec/async_object.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ struct async_construct_t {
using __construct = decltype(((_O&&)__o).async_construct(__stg, ((_An&&)__an)...));
static_assert(!stdexec::same_as<__construct, void>, "async_construct must not return void");
static_assert(stdexec::__single_typed_sender<__construct>, "async_construct must return a sender with a single set_value overload");
static_assert(stdexec::sender_of<__construct, stdexec::set_value_t(typename std::remove_cvref_t<_O>::handle)>, "async_construct must return a sender that completes with set_value(handle)");
return ((_O&&)__o).async_construct(__stg, ((_An&&)__an)...);
}
template<class _O, class _Stg, class... _An>
Expand Down

0 comments on commit 2909810

Please sign in to comment.