Skip to content

Commit f58eab0

Browse files
burblebeetkoeppe
authored andcommitted
LWG4361 awaitable-receiver::set_value should use Mandates instead of constraints
1 parent 8d7c659 commit f58eab0

1 file changed

Lines changed: 5 additions & 7 deletions

File tree

‎source/exec.tex‎

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1805,19 +1805,16 @@
18051805
static constexpr const auto& @\exposidnc{complete}@ = @\exposidnc{impls-for}@<@\exposidnc{tag-t}@>::@\exposidnc{complete}@; // \expos
18061806

18071807
template<class... Args>
1808-
requires @\exposconcept{callable}@<decltype(@\exposid{complete}@), Index, @\exposid{state-t}@&, Rcvr&, set_value_t, Args...>
18091808
void set_value(Args&&... args) && noexcept {
18101809
@\exposid{complete}@(Index(), @\exposidnc{op}@->@\exposid{state}@, @\exposidnc{op}@->@\exposid{rcvr}@, set_value_t(), std::forward<Args>(args)...);
18111810
}
18121811

18131812
template<class Error>
1814-
requires @\exposconcept{callable}@<decltype(@\exposid{complete}@), Index, @\exposid{state-t}@&, Rcvr&, set_error_t, Error>
18151813
void set_error(Error&& err) && noexcept {
18161814
@\exposid{complete}@(Index(), @\exposidnc{op}@->@\exposid{state}@, @\exposidnc{op}@->@\exposid{rcvr}@, set_error_t(), std::forward<Error>(err));
18171815
}
18181816

18191817
void set_stopped() && noexcept
1820-
requires @\exposconcept{callable}@<decltype(@\exposid{complete}@), Index, @\exposid{state-t}@&, Rcvr&, set_stopped_t> {
18211818
@\exposid{complete}@(Index(), @\exposidnc{op}@->@\exposid{state}@, @\exposidnc{op}@->@\exposid{rcvr}@, set_stopped_t());
18221819
}
18231820

@@ -6730,9 +6727,7 @@
67306727
Then:
67316728
\begin{itemize}
67326729
\item
6733-
If \tcode{\libconcept{constructible_from}<\exposid{result-type}, decltype((vs))...>}
6734-
is satisfied,
6735-
the expression \tcode{set_value(\newline rcvr, vs...)} is equivalent to:
6730+
The expression \tcode{set_value(rcvr, vs...)} is equivalent to:
67366731
\begin{codeblock}
67376732
try {
67386733
rcvr.@\exposid{result-ptr}@->template emplace<1>(vs...);
@@ -6741,7 +6736,10 @@
67416736
}
67426737
@\placeholder{MAKE-NOEXCEPT}@(rcvr.@\exposid{continuation}@.resume());
67436738
\end{codeblock}
6744-
Otherwise, \tcode{set_value(rcvr, vs...)} is ill-formed.
6739+
6740+
\mandates
6741+
\tcode{\libconcept{constructible_from}<\exposid{result-type}, decltype((vs))...>}
6742+
is satisfied.
67456743
\item
67466744
The expression \tcode{set_error(rcvr, err)} is equivalent to:
67476745
\begin{codeblock}

0 commit comments

Comments
 (0)