Skip to content

Commit 6b55e26

Browse files
committed
fixed issue-144: just using std::movable
1 parent 767bf76 commit 6b55e26

File tree

3 files changed

+14
-1
lines changed

3 files changed

+14
-1
lines changed

include/beman/execution/detail/just.hpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88
#include <beman/execution/detail/set_stopped.hpp>
99
#include <beman/execution/detail/set_value.hpp>
1010
#include <beman/execution/detail/make_sender.hpp>
11+
#include <beman/execution/detail/movable_value.hpp>
1112
#include <beman/execution/detail/product_type.hpp>
1213
#include <beman/execution/detail/completion_signatures_for.hpp>
1314
#include <beman/execution/detail/impls_for.hpp>
@@ -27,7 +28,7 @@ concept just_size = (not::std::same_as<Completion, ::beman::execution::set_error
2728
template <typename Completion>
2829
struct just_t {
2930
template <typename... T>
30-
requires ::beman::execution::detail::just_size<Completion, T...> && (::std::movable<::std::decay_t<T>> && ...)
31+
requires ::beman::execution::detail::just_size<Completion, T...> && (::beman::execution::detail::movable_value<T> && ...)
3132
auto operator()(T&&... arg) const {
3233
return ::beman::execution::detail::make_sender(
3334
*this, ::beman::execution::detail::product_type{::std::forward<T>(arg)...});

tests/beman/execution/CMakeLists.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ endif()
1111
list(
1212
APPEND
1313
execution_tests
14+
issue-144.test
1415
exec-on.test
1516
notify.test
1617
exec-scounting.test
Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
// tests/beman/execution/issue-144.test.cpp -*-C++-*-
2+
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
3+
4+
#include <beman/execution/execution.hpp>
5+
6+
namespace bex = beman::execution;
7+
8+
int main() {
9+
double d = 19.0;
10+
bex::just([d](auto) { return d; });
11+
}

0 commit comments

Comments
 (0)