summaryrefslogtreecommitdiffstats
path: root/libcxx/include/algorithm
diff options
context:
space:
mode:
authorMarshall Clow <mclow.lists@gmail.com>2017-05-25 13:40:57 +0000
committerMarshall Clow <mclow.lists@gmail.com>2017-05-25 13:40:57 +0000
commit1d02996d28a5f74933b690efc1d1bc88a4d659fe (patch)
tree4007b57a7f774e5862f69416033ca27f568615e8 /libcxx/include/algorithm
parentdc2d64bc35d5dfb3e388222eebdb4d5fe4496ca3 (diff)
downloadbcm5719-llvm-1d02996d28a5f74933b690efc1d1bc88a4d659fe.tar.gz
bcm5719-llvm-1d02996d28a5f74933b690efc1d1bc88a4d659fe.zip
Make for_each_n only avaliable on C++17
llvm-svn: 303856
Diffstat (limited to 'libcxx/include/algorithm')
-rw-r--r--libcxx/include/algorithm8
1 files changed, 5 insertions, 3 deletions
diff --git a/libcxx/include/algorithm b/libcxx/include/algorithm
index 168d2c442aa..a3bde9fa05f 100644
--- a/libcxx/include/algorithm
+++ b/libcxx/include/algorithm
@@ -964,6 +964,7 @@ for_each(_InputIterator __first, _InputIterator __last, _Function __f)
return __f;
}
+#if _LIBCPP_STD_VER > 14
// for_each_n
template <class _InputIterator, class _Size, class _Function>
@@ -981,6 +982,7 @@ for_each_n(_InputIterator __first, _Size __orig_n, _Function __f)
}
return __first;
}
+#endif
// find
@@ -1758,7 +1760,7 @@ __unwrap_iter(_Iter __i)
}
template <class _Tp>
-inline _LIBCPP_INLINE_VISIBILITY
+inline _LIBCPP_INLINE_VISIBILITY _LIBCPP_CONSTEXPR_AFTER_CXX14
typename enable_if
<
is_trivially_copy_assignable<_Tp>::value,
@@ -1772,7 +1774,7 @@ __unwrap_iter(move_iterator<_Tp*> __i)
#if _LIBCPP_DEBUG_LEVEL < 2
template <class _Tp>
-inline _LIBCPP_INLINE_VISIBILITY
+inline _LIBCPP_INLINE_VISIBILITY _LIBCPP_CONSTEXPR_AFTER_CXX14
typename enable_if
<
is_trivially_copy_assignable<_Tp>::value,
@@ -1786,7 +1788,7 @@ __unwrap_iter(__wrap_iter<_Tp*> __i)
#else
template <class _Tp>
-inline _LIBCPP_INLINE_VISIBILITY
+inline _LIBCPP_INLINE_VISIBILITY _LIBCPP_CONSTEXPR_AFTER_CXX14
typename enable_if
<
is_trivially_copy_assignable<_Tp>::value,
OpenPOWER on IntegriCloud