| 25 | { |
| 26 | |
| 27 | constexpr int test_constexpr() noexcept |
| 28 | { |
| 29 | struct receiver |
| 30 | { |
| 31 | using receiver_concept = ex::receiver_tag; |
| 32 | constexpr void set_error(int const j) && noexcept |
| 33 | { |
| 34 | i = j; |
| 35 | } |
| 36 | int& i; |
| 37 | }; |
| 38 | int i = 0; |
| 39 | auto op = ex::connect(ex::just_error(5), receiver{i}); |
| 40 | ex::start(op); |
| 41 | return i; |
| 42 | } |
| 43 | static_assert(test_constexpr() == 5); |
| 44 | |
| 45 | TEST_CASE("Simple test for just_error", "[factories][just_error]") |
no test coverage detected