Added the receiver CPOs (set_value, set_error, set_stopped)#6
Added the receiver CPOs (set_value, set_error, set_stopped)#6dietmarkuehl wants to merge 6 commits into
Conversation
dietmarkuehl
commented
Feb 6, 2022
- fixed the year of the copyright of some of the files
- added missing std:: qualification to a tag_invoke in operation_state
miscco
left a comment
There was a problem hiding this comment.
Looks good to me.
The one thing I am missing is converting calls to set_value, which should also be possible and tested
|
One obvious caveat that I forgot is that we should check that the arguments are |
|
I’ll add tests checking for conversions later today. With respect to the receiver concept: although currently it doesn’t (which I assume is a mistake) the |
| namespace _Set_stopped { | ||
| class _Cpo { | ||
| public: | ||
| template <class _Receiver> |
There was a problem hiding this comment.
If we do not go with receiver should we then constraint with movable-value?
There was a problem hiding this comment.
Maybe - that would need to go into the specification, though. The current specification just says "for some subexpression R" without adding any requirements on R. I believe the implementation allowing (and testing) the different lvalue overloads is as specified. An implementation not passing these tests does not match the specification.