[exec.stopped.opt]/para 3 reads:
- Let
sndr and env be subexpressions such that Sndr is decltype((sndr)) and Env is decltype((env)). If sender-for<Sndr, stopped_as_optional_t> is false, or if the type single-sender-value-type<Sndr, Env> is ill-formed or void, then the expression stopped_as_optional.transform_sender(sndr, env) is ill-formed; otherwise, it is equivalent to:
the test for single-sender-value-type<Sndr, Env> is incorrect. it should be testing its child for single-sender-ness.
In addition, it should be applying FWD-ENV-T to Env so that only forwarding queries are forwarded.
Proposed resolution
Change single-sender-value-type<Sndr, Env> to single-sender-value-type<child-type<Sndr>, FWD-ENV-T(Env)> in [exec.stopped.opt] para 2 (twice!), where FWD-ENV-T is specified as in #313.
[exec.stopped.opt]/para 3 reads:
the test for
single-sender-value-type<Sndr, Env>is incorrect. it should be testing its child for single-sender-ness.In addition, it should be applying
FWD-ENV-TtoEnvso that only forwarding queries are forwarded.Proposed resolution
Change
single-sender-value-type<Sndr, Env>tosingle-sender-value-type<child-type<Sndr>, FWD-ENV-T(Env)>in [exec.stopped.opt] para 2 (twice!), whereFWD-ENV-Tis specified as in #313.