diff options
Diffstat (limited to 'libcxx/include/__algorithm/min_element.h')
| -rw-r--r-- | libcxx/include/__algorithm/min_element.h | 11 | 
1 files changed, 5 insertions, 6 deletions
| diff --git a/libcxx/include/__algorithm/min_element.h b/libcxx/include/__algorithm/min_element.h index 17b242c341e6..c0706fe9e44d 100644 --- a/libcxx/include/__algorithm/min_element.h +++ b/libcxx/include/__algorithm/min_element.h @@ -25,7 +25,7 @@  _LIBCPP_BEGIN_NAMESPACE_STD  template <class _Comp, class _Iter, class _Sent, class _Proj> -inline _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR_AFTER_CXX11 +inline _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR_SINCE_CXX14  _Iter __min_element(_Iter __first, _Sent __last, _Comp __comp, _Proj& __proj) {    if (__first == __last)      return __first; @@ -39,14 +39,14 @@ _Iter __min_element(_Iter __first, _Sent __last, _Comp __comp, _Proj& __proj) {  }  template <class _Comp, class _Iter, class _Sent> -_LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR_AFTER_CXX11 +_LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR_SINCE_CXX14  _Iter __min_element(_Iter __first, _Sent __last, _Comp __comp) {    auto __proj = __identity();    return std::__min_element<_Comp>(std::move(__first), std::move(__last), __comp, __proj);  }  template <class _ForwardIterator, class _Compare> -_LIBCPP_NODISCARD_EXT inline _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR_AFTER_CXX11 _ForwardIterator +_LIBCPP_NODISCARD_EXT inline _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR_SINCE_CXX14 _ForwardIterator  min_element(_ForwardIterator __first, _ForwardIterator __last, _Compare __comp)  {    static_assert(__is_cpp17_forward_iterator<_ForwardIterator>::value, @@ -54,12 +54,11 @@ min_element(_ForwardIterator __first, _ForwardIterator __last, _Compare __comp)    static_assert(__is_callable<_Compare, decltype(*__first), decltype(*__first)>::value,                "The comparator has to be callable"); -  typedef typename __comp_ref_type<_Compare>::type _Comp_ref; -  return std::__min_element<_Comp_ref>(std::move(__first), std::move(__last), __comp); +  return std::__min_element<__comp_ref_type<_Compare> >(std::move(__first), std::move(__last), __comp);  }  template <class _ForwardIterator> -_LIBCPP_NODISCARD_EXT inline _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR_AFTER_CXX11 _ForwardIterator +_LIBCPP_NODISCARD_EXT inline _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR_SINCE_CXX14 _ForwardIterator  min_element(_ForwardIterator __first, _ForwardIterator __last)  {      return _VSTD::min_element(__first, __last, | 
