summaryrefslogtreecommitdiff
path: root/libstdc++-v3/include/parallel
diff options
context:
space:
mode:
Diffstat (limited to 'libstdc++-v3/include/parallel')
-rw-r--r--libstdc++-v3/include/parallel/algo.h15
1 files changed, 15 insertions, 0 deletions
diff --git a/libstdc++-v3/include/parallel/algo.h b/libstdc++-v3/include/parallel/algo.h
index cec6fd003c3..4b6dcc84119 100644
--- a/libstdc++-v3/include/parallel/algo.h
+++ b/libstdc++-v3/include/parallel/algo.h
@@ -1049,6 +1049,21 @@ namespace __parallel
std::__iterator_category(__begin2));
}
+#if __cplusplus >= 201703L
+ /** @brief Search a sequence using a Searcher object.
+ *
+ * @param __first A forward iterator.
+ * @param __last A forward iterator.
+ * @param __searcher A callable object.
+ * @return @p __searcher(__first,__last).first
+ */
+ template<typename _ForwardIterator, typename _Searcher>
+ inline _ForwardIterator
+ search(_ForwardIterator __first, _ForwardIterator __last,
+ const _Searcher& __searcher)
+ { return __searcher(__first, __last).first; }
+#endif
+
// Sequential fallback
template<typename _FIterator, typename _Integer, typename _Tp>
inline _FIterator