@@ -217,7 +217,11 @@ namespace hpx::execution::experimental {
217217 {
218218 auto shape_begin = hpx::util::begin (shape);
219219 auto args_tuple = hpx::make_tuple (HPX_FORWARD (Ts, ts)...);
220+ #if defined(HPX_HAVE_STDEXEC)
220221 return make_future (bulk (schedule (exec.sched_ ), hpx::execution::experimental::par,
222+ #else
223+ return make_future (bulk (schedule (exec.sched_ ), hpx::execution::par,
224+ #endif
221225 hpx::util::size (shape),
222226 [func = std::decay_t <F>(HPX_FORWARD (F, f)), shape_begin,
223227 args_tuple = HPX_MOVE (args_tuple)](auto idx) mutable {
@@ -267,7 +271,11 @@ namespace hpx::execution::experimental {
267271 start_detached (
268272 bulk (transfer_just (exec.sched_ , HPX_MOVE (promises),
269273 HPX_FORWARD (F, f), shape, HPX_FORWARD (Ts, ts)...),
274+ #if defined(HPX_HAVE_STDEXEC)
270275 hpx::execution::experimental::par, n, HPX_MOVE (f_helper)));
276+ #else
277+ hpx::execution::par, n, HPX_MOVE (f_helper)));
278+ #endif
271279
272280 return results;
273281 }
@@ -287,7 +295,11 @@ namespace hpx::execution::experimental {
287295 auto shape_begin = hpx::util::begin (shape);
288296 auto args_tuple = hpx::make_tuple (HPX_FORWARD (Ts, ts)...);
289297 hpx::this_thread::experimental::sync_wait (bulk (
298+ #if defined(HPX_HAVE_STDEXEC)
290299 schedule (exec.sched_ ), hpx::execution::experimental::par, hpx::util::size (shape),
300+ #else
301+ schedule (exec.sched_ ), hpx::execution::par, hpx::util::size (shape),
302+ #endif
291303 [func = std::decay_t <F>(HPX_FORWARD (F, f)), shape_begin,
292304 args_tuple = HPX_MOVE (args_tuple)](auto idx) mutable {
293305 auto it = shape_begin;
@@ -325,7 +337,11 @@ namespace hpx::execution::experimental {
325337 auto shape_begin = hpx::util::begin (shape);
326338 auto args_tuple = hpx::make_tuple (HPX_FORWARD (Ts, ts)...);
327339 auto loop = bulk (transfer (HPX_MOVE (pre_req), exec.sched_ ),
340+ #if defined(HPX_HAVE_STDEXEC)
328341 hpx::execution::experimental::par, hpx::util::size (shape),
342+ #else
343+ hpx::execution::par, hpx::util::size (shape),
344+ #endif
329345 [func = std::decay_t <F>(HPX_FORWARD (F, f)), shape_begin,
330346 args_tuple = HPX_MOVE (args_tuple)](auto idx) mutable {
331347 auto it = shape_begin;
@@ -350,7 +366,11 @@ namespace hpx::execution::experimental {
350366 auto shape_begin = hpx::util::begin (shape);
351367 auto args_tuple = hpx::make_tuple (HPX_FORWARD (Ts, ts)...);
352368 auto loop = bulk (transfer (HPX_MOVE (pre_req), exec.sched_ ),
369+ #if defined(HPX_HAVE_STDEXEC)
353370 hpx::execution::experimental::par, hpx::util::size (shape),
371+ #else
372+ hpx::execution::par, hpx::util::size (shape),
373+ #endif
354374 [func = std::decay_t <F>(HPX_FORWARD (F, f)), shape_begin,
355375 args_tuple = HPX_MOVE (args_tuple)](
356376 auto idx, std::vector<result_type>& results) mutable {
0 commit comments