[libcxx-commits] [PATCH] D59813: The other fix for equal algo

Louis Dionne via Phabricator via libcxx-commits libcxx-commits at lists.llvm.org
Tue Mar 26 07:01:43 PDT 2019


ldionne added inline comments.


================
Comment at: include/pstl/internal/algorithm_impl.h:409
+bool
+equal_serial_impl(_ForwardIterator1 __first1, _ForwardIterator1 __last1, _ForwardIterator2 __first2,
+                  _ForwardIterator2 __last2, _BinaryPredicate __p)
----------------
MikeDvorskiy wrote:
> ldionne wrote:
> > This can also be called as `std::equal(first1, last1, first2, last2, pred)`. Is there any reason why we don't assume the presence of the usual `std::equal`?
> ```
> std::equal(first1, last1, first2, last2... 
> ```
> supported since C++14...  Parallel STL open source version has min requirement  C++11.
> 
> Actually, we can add a macro __PSTL_EQUAL_ALGO_VERSION_2_PRESENT
> and re-call std::equal or our own serial implementation.
> 
The parallel algorithms are a C++17 addition, and as such they can require C++17 support.


Repository:
  rPSTL pstl

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D59813/new/

https://reviews.llvm.org/D59813





More information about the libcxx-commits mailing list