aboutsummaryrefslogtreecommitdiff
path: root/contrib/llvm-project/libcxx/include/__iterator/prev.h
diff options
context:
space:
mode:
Diffstat (limited to 'contrib/llvm-project/libcxx/include/__iterator/prev.h')
-rw-r--r--contrib/llvm-project/libcxx/include/__iterator/prev.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/contrib/llvm-project/libcxx/include/__iterator/prev.h b/contrib/llvm-project/libcxx/include/__iterator/prev.h
index d31cd8e49bbf..3bc29a27e743 100644
--- a/contrib/llvm-project/libcxx/include/__iterator/prev.h
+++ b/contrib/llvm-project/libcxx/include/__iterator/prev.h
@@ -24,13 +24,13 @@
_LIBCPP_BEGIN_NAMESPACE_STD
-template <class _InputIter>
-inline _LIBCPP_INLINE_VISIBILITY _LIBCPP_CONSTEXPR_SINCE_CXX17
- typename enable_if<__has_input_iterator_category<_InputIter>::value, _InputIter>::type
+template <class _InputIter, __enable_if_t<__has_input_iterator_category<_InputIter>::value, int> = 0>
+inline _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR_SINCE_CXX17
+ _InputIter
prev(_InputIter __x, typename iterator_traits<_InputIter>::difference_type __n = 1) {
_LIBCPP_ASSERT_UNCATEGORIZED(__n <= 0 || __has_bidirectional_iterator_category<_InputIter>::value,
"Attempt to prev(it, n) with a positive n on a non-bidirectional iterator");
- _VSTD::advance(__x, -__n);
+ std::advance(__x, -__n);
return __x;
}