This page is a snapshot from the LWG issues list, see the Library Active Issues List for more information and the meaning of New status.
awaitable-sender concept should qualify use of awaitable-receiver typeSection: 33.13.1 [exec.as.awaitable] Status: New Submitter: Lewis Baker Opened: 2025-08-27 Last modified: 2025-10-23
Priority: 2
View other active issues in [exec.as.awaitable].
View all other issues in [exec.as.awaitable].
View all issues with New status.
Discussion:
In 33.13.1 [exec.as.awaitable] p1 there is an exposition-only helper concept
awaitable-sender defined as follows:
namespace std::execution {
template<class Sndr, class Promise>
concept awaitable-sender =
single-sender<Sndr, env_of_t<Promise>> &&
sender_to<Sndr, awaitable-receiver> && // see below
requires (Promise& p) {
{ p.unhandled_stopped() } -> convertible_to<coroutine_handle<>>;
};
}
The mention of the type awaitable-receiver here does not refer to any exposition-only type
defined at namespace-scope. It seems to, instead, be referring to the nested member-type
sender-awaitable<Sndr, Promise>::awaitable-receiver and so should be
qualified as such.
[2025-10-23; Reflector poll.]
Set priority to 2 after reflector poll.
"We should move the declaration of sender-awaitable before the concept."
Proposed resolution:
This wording is relative to N5014.
Modify 33.13.1 [exec.as.awaitable] as indicated:
-1-
as_awaitabletransforms an object into one that is awaitable within a particular coroutine. Subclause 33.13 [exec.coro.util] makes use of the following exposition-only entities:namespace std::execution { template<class Sndr, class Promise> concept awaitable-sender = single-sender<Sndr, env_of_t<Promise>> && sender_to<Sndr, typename sender-awaitable<Sndr, Promise>::awaitable-receiver> && // see below requires (Promise& p) { { p.unhandled_stopped() } -> convertible_to<coroutine_handle<>>; }; […] }