Skip to content

[2025-06-lwg-24] P3557R3 High-Quality Sender Diagnostics with Constexpr Exceptions #8035

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

burblebee
Copy link
Contributor

@burblebee burblebee commented Jul 1, 2025

  • [exec.util.cmplsig] Subclause (now without siblings) promoted to \rSec1 (replacing [exec.util]) and renamed to [exec.cmplsig] "Completion signatures".
  • [exec.snd.expos]p24 Added missing \expos comments.
  • FIXED: [exec.snd.expos]p39 Unable to find paragraph to replace. Referenced paragraph starts: "Let Sndr be a (possibly const-qualified) specialization basic-sender" Inserted changes as new text after [exec.snd.expos]p41 instead.
  • FIXED: [exec.write.env] Unable to apply changes - section does not exist. Referenced paragraph starts: "write_env is a sender adaptor that accepts a sender and a queryable object"

Also fixes LWG4203.

Fixes #7961.

@jensmaurer
Copy link
Member

write_env is added here: #7973

@burblebee
Copy link
Contributor Author

#7973
Thanks Jens!

So rebasing on motions-2025-06-lwg-5 will give me [exec.write.env] from P3284R4 (so I can apply changes to [exec.write.env]), but change to [exec.snd.expos]p39 is still a problem, because the wording it changes assumes P3164R4 was applied.

@burblebee burblebee force-pushed the motions-2025-06-lwg-24 branch 2 times, most recently from 8fc26dd to a91ff84 Compare July 1, 2025 22:34
@burblebee burblebee marked this pull request as ready for review July 1, 2025 22:35
@burblebee
Copy link
Contributor Author

So rebasing on motions-2025-06-lwg-5 will give me [exec.write.env] from P3284R4 (so I can apply changes to [exec.write.env]), but change to [exec.snd.expos]p39 is still a problem, because the wording it changes assumes P3164R4 was applied.

  • Now rebased on motions-2025-06-lwg-5
  • Replaced [exec.snd.expos]p39 based on changes in P3164R4

Edits should all be in now.

@burblebee burblebee marked this pull request as draft July 2, 2025 02:15
* [exec.util.cmplsig] Subclause (now without siblings) promoted to \rSec1
  (replacing [exec.util]) and renamed to [exec.cmplsig] "Completion signatures".

Also fixes LWG4203.
@burblebee burblebee force-pushed the motions-2025-06-lwg-24 branch from a91ff84 to 961293f Compare July 2, 2025 05:35
@burblebee burblebee marked this pull request as ready for review July 2, 2025 05:47
Then the type of the expression \tcode{get_completion_signatures(sndr, env)} is
this set of completion operations, and
let \tcode{CS} be
the type of the expression \tcode{get_completion_signatures(Sndr, Env)()}.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should be:

Suggested change
the type of the expression \tcode{get_completion_signatures(Sndr, Env)()}.
the type of the expression \tcode{get_completion_signatures<Sndr, Env>()}.

Comment on lines 1966 to 2010
\begin{itemdescr}
\pnum
\exposid{write-env} is an exposition-only sender adaptor that,
when connected with a receiver \tcode{rcvr},
connects the adapted sender with a receiver
whose execution environment is the result of
joining the \exposconcept{queryable} argument \tcode{env}
to the result of \tcode{get_env(rcvr)}.

\pnum
Let \exposid{write-env-t} be an exposition-only empty class type.

\pnum
\returns
\begin{codeblock}
@\exposid{make-sender}@(@\exposid{write-env-t}@(), std::forward<Env>(env), std::forward<Sndr>(sndr))
\end{codeblock}

\pnum
\remarks
The exposition-only class template \exposid{impls-for}\iref{exec.snd.general}
is specialized for \exposid{write-env-t} as follows:
\begin{codeblock}
template<>
struct @\exposid{impls-for}@<@\exposid{write-env-t}@> : @\exposid{default-impls}@ {
static constexpr auto @\exposid{get-env}@ =
[](auto, const auto& state, const auto& rcvr) noexcept {
return @\seebelow@;
};
};
\end{codeblock}
Invocation of
\tcode{\exposid{impls-for}<\exposid{write-env-t}>::\exposid{get-env}}
returns an object \tcode{e} such that
\begin{itemize}
\item
\tcode{decltype(e)} models \exposconcept{queryable} and
\item
given a query object \tcode{q},
the expression \tcode{e.query(q)} is expression-equivalent
to \tcode{state.query(q)} if that expression is valid,
otherwise, \tcode{e.query(q)} is expression-equivalent
to \tcode{get_env(rcvr).que\-ry(q)}.
\end{itemize}
\end{itemdescr}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is old wording for what used to be the write-env exposition-only function. P3284 removed this wording and added the execution::write_env sender adaptor.

@@ -1906,14 +2098,16 @@
@\libconcept{move_constructible}@<remove_cvref_t<Sndr>> &&
@\libconcept{constructible_from}@<remove_cvref_t<Sndr>, Sndr>;

template<class Sndr, class Env = env<>>
template<class Sndr, class Env>
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
template<class Sndr, class Env>
template<class Sndr, class... Env>

\pnum
Let \tcode{\placeholder{when-all-env}} be an alias template such that
\tcode{\placeholder{when-all-env}<Env>} denotes the type
\tcode{decltype(\exposid{mmake-\linebreak{}when-all-env}(declval<inplace_stop_source\&>(), declval<Env>()))}.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
\tcode{decltype(\exposid{mmake-\linebreak{}when-all-env}(declval<inplace_stop_source\&>(), declval<Env>()))}.
\tcode{decltype(\exposid{make-\linebreak{}when-all-env}(declval<inplace_stop_source\&>(), declval<Env>()))}.

otherwise, \exposid{none-such},
where \exposid{none-such} is an unspecified empty class type.
otherwise, \tcode{\placeholder{none-such}},
where \tcode{\placeholder{none-such}} is an unspecified empty class type.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

just curious, why did these change from \exposid to \placeholder? i don't know what the difference it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[2025-06 LWG Motion 24] P3557R3 High-Quality Sender Diagnostics with Constexpr Exceptions
3 participants