Skip to content

Commit f5ba8b5

Browse files
authored
Merge pull request #1554 from ericniebler/get-domain-override
rename `get_domain_late` to `get_domain_override`
2 parents a8cbd72 + fe78e66 commit f5ba8b5

7 files changed

Lines changed: 18 additions & 18 deletions

File tree

include/nvexec/stream/common.cuh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -370,7 +370,7 @@ namespace nvexec {
370370

371371
STDEXEC_ATTRIBUTE(nodiscard)
372372

373-
constexpr auto query(get_domain_late_t) const noexcept -> stream_domain {
373+
constexpr auto query(get_domain_override_t) const noexcept -> stream_domain {
374374
return {};
375375
}
376376

include/nvexec/stream/when_all.cuh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -150,7 +150,7 @@ namespace nvexec::_strm {
150150
}
151151
}
152152

153-
constexpr auto query(get_domain_late_t) const noexcept
153+
constexpr auto query(get_domain_override_t) const noexcept
154154
requires stdexec::__same_as<WhenAllTag, transfer_when_all_t>
155155
{
156156
static_assert(

include/stdexec/__detail/__domain.hpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -144,8 +144,8 @@ namespace stdexec {
144144
// The schedule_from algorithm is the exception to the rule. It ignores the domain
145145
// of the predecessor, and dispatches based on the domain of the scheduler to
146146
// which execution is being transferred.
147-
if constexpr (__callable<get_domain_late_t, env_of_t<_Sender>>) {
148-
return get_domain_late(get_env(__sndr));
147+
if constexpr (__callable<get_domain_override_t, env_of_t<_Sender>>) {
148+
return get_domain_override(get_env(__sndr));
149149
} else if constexpr (__callable<get_domain_t, const _Env&>) {
150150
return get_domain(__env);
151151
} else if constexpr (__callable<__composed<get_domain_t, get_scheduler_t>, const _Env&>) {

include/stdexec/__detail/__env.hpp

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -224,17 +224,17 @@ namespace stdexec {
224224
}
225225
};
226226

227-
struct get_domain_late_t {
227+
struct get_domain_override_t {
228228
template <class _Ty>
229-
requires tag_invocable<get_domain_late_t, const _Ty&>
229+
requires tag_invocable<get_domain_override_t, const _Ty&>
230230
constexpr auto operator()(const _Ty&) const noexcept
231-
-> __decay_t<tag_invoke_result_t<get_domain_late_t, const _Ty&>> {
231+
-> __decay_t<tag_invoke_result_t<get_domain_override_t, const _Ty&>> {
232232
static_assert(
233-
nothrow_tag_invocable<get_domain_late_t, const _Ty&>,
234-
"Customizations of get_domain_late must be noexcept.");
233+
nothrow_tag_invocable<get_domain_override_t, const _Ty&>,
234+
"Customizations of get_domain_override must be noexcept.");
235235
static_assert(
236-
__class<__decay_t<tag_invoke_result_t<get_domain_late_t, const _Ty&>>>,
237-
"Customizations of get_domain_late must return a class type.");
236+
__class<__decay_t<tag_invoke_result_t<get_domain_override_t, const _Ty&>>>,
237+
"Customizations of get_domain_override must return a class type.");
238238
return {};
239239
}
240240

@@ -296,7 +296,7 @@ namespace stdexec {
296296
using __queries::get_stop_token_t;
297297
using __queries::get_completion_scheduler_t;
298298
using __queries::get_domain_t;
299-
using __queries::get_domain_late_t;
299+
using __queries::get_domain_override_t;
300300
using __queries::__is_scheduler_affine_t;
301301
using __queries::__root_t;
302302
using __queries::__root_env;
@@ -329,7 +329,7 @@ namespace stdexec {
329329
concept __forwarding_query = forwarding_query(_Tag{});
330330

331331
inline constexpr get_domain_t get_domain{};
332-
inline constexpr get_domain_late_t get_domain_late{};
332+
inline constexpr get_domain_override_t get_domain_override{};
333333

334334
template <class _Tag, class _Queryable, class _Default>
335335
using __query_result_or_t = __call_result_t<query_or_t, _Tag, _Queryable, _Default>;
@@ -688,7 +688,7 @@ namespace stdexec {
688688
return {};
689689
}
690690

691-
constexpr auto query(get_domain_late_t) const noexcept -> _LateDomain
691+
constexpr auto query(get_domain_override_t) const noexcept -> _LateDomain
692692
requires(!same_as<_LateDomain, __none_such>)
693693
{
694694
return {};

test/stdexec/algos/consumers/test_start_detached.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -113,7 +113,7 @@ namespace {
113113

114114
[[nodiscard]]
115115
auto get_env() const noexcept {
116-
return ex::prop{ex::get_domain_late, domain{}};
116+
return ex::prop{ex::get_domain_override, domain{}};
117117
}
118118

119119
template <class Receiver>

test/stdexec/algos/consumers/test_sync_wait.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -223,7 +223,7 @@ namespace {
223223
TEST_CASE("sync_wait can be customized", "[consumers][sync_wait]") {
224224
// The customization will return a different value
225225
auto snd = ex::just(std::string{"hello"})
226-
| exec::write_attrs(ex::prop{ex::get_domain_late, sync_wait_test_domain{}});
226+
| exec::write_attrs(ex::prop{ex::get_domain_override, sync_wait_test_domain{}});
227227
auto res = ex::sync_wait(std::move(snd));
228228
STATIC_REQUIRE(std::same_as<decltype(res), sync_wait_test_domain::single_result_t>);
229229
CHECK(res.has_value());
@@ -233,7 +233,7 @@ namespace {
233233
TEST_CASE("sync_wait_with_variant can be customized", "[consumers][sync_wait_with_variant]") {
234234
// The customization will return a different value
235235
auto snd = fallible_just(std::string{"hello_multi"}) | ex::let_error(always(ex::just(42)))
236-
| exec::write_attrs(ex::prop{ex::get_domain_late, sync_wait_test_domain{}});
236+
| exec::write_attrs(ex::prop{ex::get_domain_override, sync_wait_test_domain{}});
237237
auto res = ex::sync_wait_with_variant(std::move(snd));
238238
STATIC_REQUIRE(std::same_as<decltype(res), sync_wait_test_domain::multi_result_t>);
239239
CHECK(res.has_value());

test/stdexec/cpos/cpo_helpers.cuh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ namespace {
5656
}
5757

5858
[[nodiscard]]
59-
auto query(ex::get_domain_late_t) const noexcept {
59+
auto query(ex::get_domain_override_t) const noexcept {
6060
return cpo_sender_domain{};
6161
}
6262
};

0 commit comments

Comments
 (0)