[libcxx-commits] [libcxx] [libc++] Forward find* algorithms to find_if (PR #179938)
Louis Dionne via libcxx-commits
libcxx-commits at lists.llvm.org
Wed Feb 25 07:59:54 PST 2026
================
@@ -48,10 +49,11 @@ _LIBCPP_BEGIN_NAMESPACE_STD
template <class _Iter, class _Sent, class _Tp, class _Proj>
_LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR_SINCE_CXX14 _Iter
__find_loop(_Iter __first, _Sent __last, const _Tp& __value, _Proj& __proj) {
- for (; __first != __last; ++__first)
- if (std::__invoke(__proj, *__first) == __value)
- break;
- return __first;
+ return std::__find_if(
----------------
ldionne wrote:
Yeah, I think renaming the function would resolve my concern.
https://github.com/llvm/llvm-project/pull/179938
More information about the libcxx-commits
mailing list