@@ -230,10 +230,10 @@ namespace experimental::execution
230230 template <class ... _Senders>
231231 struct item_types
232232 {
233- template <class _Fn , class _Continuation = STDEXEC::__qq<STDEXEC::__mlist> >
234- static constexpr auto __transform (_Fn __fn, _Continuation __continuation = {} )
233+ template <class _Transform , class _Reduce >
234+ static constexpr auto __transform ([[maybe_unused]] _Transform _transform, _Reduce _reduce )
235235 {
236- return __continuation (__fn .template operator ()<_Senders>()...);
236+ return _reduce (_transform .template operator ()<_Senders>()...);
237237 }
238238 };
239239
@@ -253,42 +253,6 @@ namespace experimental::execution
253253 struct _FAILED_TO_COMPUTE_SEQUENCE_ITEM_TYPES_
254254 {};
255255
256- #if STDEXEC_NO_STDCPP_CONSTEXPR_EXCEPTIONS()
257-
258- template <class ... _What, class ... _Values>
259- [[nodiscard]]
260- consteval auto __invalid_item_types (_Values...)
261- {
262- return STDEXEC::__mexception<_What...>();
263- }
264-
265- #else // ^^^ no constexpr exceptions ^^^ / vvv constexpr exceptions vvv
266-
267- // C++26, https://wg21.link/p3068
268- template <class _What , class ... _More, class ... _Values>
269- [[noreturn, nodiscard]]
270- consteval auto __invalid_item_types ([[maybe_unused]] _Values... __values) -> item_types<>
271- {
272- if constexpr (sizeof ...(_Values) == 1 )
273- {
274- throw __sequence_type_check_failure<_Values..., _What, _More...>(__values...);
275- }
276- else
277- {
278- throw __sequence_type_check_failure<STDEXEC::__tuple<_Values...>, _What, _More...>(
279- STDEXEC::__tuple{__values...});
280- }
281- }
282-
283- #endif // ^^^ constexpr exceptions ^^^
284-
285- template <class ... _What>
286- [[nodiscard]]
287- consteval auto __invalid_item_types (STDEXEC::__mexception<_What...>)
288- {
289- return exec::__invalid_item_types<_What...>();
290- }
291-
292256 template <class _Sequence , class ... _Env>
293257 using __unrecognized_sequence_error_t =
294258 STDEXEC::__mexception<STDEXEC::_WHAT_(_UNRECOGNIZED_SEQUENCE_TYPE_),
@@ -376,11 +340,12 @@ namespace experimental::execution
376340 }
377341 else if constexpr (sizeof ...(_Env) == 0 )
378342 {
379- return STDEXEC::__dependent_sender< _Sequence>();
343+ return STDEXEC::__dependent_sender_r<item_types<>, _Sequence>();
380344 }
381345 else
382346 {
383- return __unrecognized_sequence_error_t <_Sequence, _Env...>();
347+ return STDEXEC::__throw_compile_time_error_r<item_types<>>(
348+ __unrecognized_sequence_error_t <_Sequence, _Env...>());
384349 }
385350 }
386351
@@ -591,6 +556,46 @@ namespace experimental::execution
591556 _Data __data_{};
592557 };
593558
559+ #if STDEXEC_NO_STDCPP_CONSTEXPR_EXCEPTIONS()
560+
561+ template <class ... _What, class ... _Values>
562+ [[nodiscard]]
563+ consteval auto __invalid_item_types (_Values...)
564+ {
565+ return STDEXEC::__mexception<_What...>();
566+ }
567+
568+ #else // ^^^ no constexpr exceptions ^^^ / vvv constexpr exceptions vvv
569+
570+ // C++26, https://wg21.link/p3068
571+ template <class _What , class ... _More, class ... _Values>
572+ [[noreturn, nodiscard]]
573+ consteval auto __invalid_item_types ([[maybe_unused]] _Values... __values) -> item_types<>
574+ {
575+ if constexpr (STDEXEC::__same_as<_What, STDEXEC::dependent_sender_error>)
576+ {
577+ throw STDEXEC::__mexception<STDEXEC::dependent_sender_error, _More...>();
578+ }
579+ else if constexpr (sizeof ...(_Values) == 1 )
580+ {
581+ throw __sequence_type_check_failure<_Values..., _What, _More...>(__values...);
582+ }
583+ else
584+ {
585+ throw __sequence_type_check_failure<STDEXEC::__tuple<_Values...>, _What, _More...>(
586+ STDEXEC::__tuple<_Values...>{__values...});
587+ }
588+ }
589+
590+ #endif // ^^^ constexpr exceptions ^^^
591+
592+ template <class ... _What>
593+ [[nodiscard]]
594+ consteval auto __invalid_item_types (STDEXEC::__mexception<_What...>)
595+ {
596+ return exec::__invalid_item_types<_What...>();
597+ }
598+
594599 struct _MISSING_SET_NEXT_OVERLOAD_FOR_ITEM_
595600 {};
596601
0 commit comments