[libcxx-commits] [libcxx] [libc++][pstl] Default implementation of parallel std::adjacent_difference (PR #207585)
Louis Dionne via libcxx-commits
libcxx-commits at lists.llvm.org
Wed Jul 8 08:48:26 PDT 2026
================
@@ -529,6 +530,34 @@ struct __rotate_copy<__default_backend_tag, _ExecutionPolicy> {
}
};
+template <class _ExecutionPolicy>
+struct __adjacent_difference<__default_backend_tag, _ExecutionPolicy> {
+ template <class _Policy, class _ForwardIterator1, class _ForwardIterator2, class _BinaryOperation>
+ [[nodiscard]] _LIBCPP_HIDE_FROM_ABI optional<_ForwardIterator2>
+ operator()(_Policy&& __policy,
+ _ForwardIterator1 __first1,
+ _ForwardIterator1 __last1,
+ _ForwardIterator2 __first2,
----------------
ldionne wrote:
I would suggest calling this `__out` or `__dest` or `__result`. Non-blocking, just a preference.
https://github.com/llvm/llvm-project/pull/207585
More information about the libcxx-commits
mailing list