diff options
| author | Dimitry Andric <dim@FreeBSD.org> | 2022-03-20 11:40:34 +0000 |
|---|---|---|
| committer | Dimitry Andric <dim@FreeBSD.org> | 2022-05-14 11:43:05 +0000 |
| commit | 349cc55c9796c4596a5b9904cd3281af295f878f (patch) | |
| tree | 410c5a785075730a35f1272ca6a7adf72222ad03 /contrib/llvm-project/libcxx/include/__algorithm/remove_if.h | |
| parent | cb2ae6163174b90e999326ecec3699ee093a5d43 (diff) | |
| parent | c0981da47d5696fe36474fcf86b4ce03ae3ff818 (diff) | |
Diffstat (limited to 'contrib/llvm-project/libcxx/include/__algorithm/remove_if.h')
| -rw-r--r-- | contrib/llvm-project/libcxx/include/__algorithm/remove_if.h | 9 |
1 files changed, 1 insertions, 8 deletions
diff --git a/contrib/llvm-project/libcxx/include/__algorithm/remove_if.h b/contrib/llvm-project/libcxx/include/__algorithm/remove_if.h index e506b4c67fba..4df36896afd5 100644 --- a/contrib/llvm-project/libcxx/include/__algorithm/remove_if.h +++ b/contrib/llvm-project/libcxx/include/__algorithm/remove_if.h @@ -12,23 +12,18 @@ #include <__config> #include <__algorithm/find_if.h> #include <utility> -#include <type_traits> #if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) #pragma GCC system_header #endif -_LIBCPP_PUSH_MACROS -#include <__undef_macros> - _LIBCPP_BEGIN_NAMESPACE_STD template <class _ForwardIterator, class _Predicate> _LIBCPP_NODISCARD_EXT _LIBCPP_CONSTEXPR_AFTER_CXX17 _ForwardIterator remove_if(_ForwardIterator __first, _ForwardIterator __last, _Predicate __pred) { - __first = _VSTD::find_if<_ForwardIterator, typename add_lvalue_reference<_Predicate>::type> - (__first, __last, __pred); + __first = _VSTD::find_if<_ForwardIterator, _Predicate&>(__first, __last, __pred); if (__first != __last) { _ForwardIterator __i = __first; @@ -46,6 +41,4 @@ remove_if(_ForwardIterator __first, _ForwardIterator __last, _Predicate __pred) _LIBCPP_END_NAMESPACE_STD -_LIBCPP_POP_MACROS - #endif // _LIBCPP___ALGORITHM_REMOVE_IF_H |
