Upgrade to 2022-era LLVM LIBCXX

This commit is contained in:
Justine Tunney 2024-05-27 02:12:27 -07:00
parent 2f4ca71f26
commit 8e68384e15
No known key found for this signature in database
GPG key ID: BE714B4575D6E328
2078 changed files with 165657 additions and 65010 deletions

View file

@ -1,5 +1,5 @@
// -*- C++ -*-
//===----------------------- initializer_list -----------------------------===//
//===----------------------------------------------------------------------===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
@ -42,11 +42,12 @@ template<class E> const E* end(initializer_list<E> il) noexcept; // constexpr in
*/
#include "third_party/libcxx/__config"
#include "third_party/libcxx/cstddef"
#include <__assert> // all public C++ headers provide the assertion handler
#include <__config>
#include <cstddef>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
# pragma GCC system_header
#endif
namespace std // purposefully not versioned
@ -61,7 +62,7 @@ class _LIBCPP_TEMPLATE_VIS initializer_list
size_t __size_;
_LIBCPP_INLINE_VISIBILITY
_LIBCPP_CONSTEXPR_AFTER_CXX11
_LIBCPP_CONSTEXPR_SINCE_CXX14
initializer_list(const _Ep* __b, size_t __s) _NOEXCEPT
: __begin_(__b),
__size_(__s)
@ -76,25 +77,25 @@ public:
typedef const _Ep* const_iterator;
_LIBCPP_INLINE_VISIBILITY
_LIBCPP_CONSTEXPR_AFTER_CXX11
_LIBCPP_CONSTEXPR_SINCE_CXX14
initializer_list() _NOEXCEPT : __begin_(nullptr), __size_(0) {}
_LIBCPP_INLINE_VISIBILITY
_LIBCPP_CONSTEXPR_AFTER_CXX11
_LIBCPP_CONSTEXPR_SINCE_CXX14
size_t size() const _NOEXCEPT {return __size_;}
_LIBCPP_INLINE_VISIBILITY
_LIBCPP_CONSTEXPR_AFTER_CXX11
_LIBCPP_CONSTEXPR_SINCE_CXX14
const _Ep* begin() const _NOEXCEPT {return __begin_;}
_LIBCPP_INLINE_VISIBILITY
_LIBCPP_CONSTEXPR_AFTER_CXX11
_LIBCPP_CONSTEXPR_SINCE_CXX14
const _Ep* end() const _NOEXCEPT {return __begin_ + __size_;}
};
template<class _Ep>
inline _LIBCPP_INLINE_VISIBILITY
_LIBCPP_CONSTEXPR_AFTER_CXX11
_LIBCPP_CONSTEXPR_SINCE_CXX14
const _Ep*
begin(initializer_list<_Ep> __il) _NOEXCEPT
{
@ -103,15 +104,15 @@ begin(initializer_list<_Ep> __il) _NOEXCEPT
template<class _Ep>
inline _LIBCPP_INLINE_VISIBILITY
_LIBCPP_CONSTEXPR_AFTER_CXX11
_LIBCPP_CONSTEXPR_SINCE_CXX14
const _Ep*
end(initializer_list<_Ep> __il) _NOEXCEPT
{
return __il.end();
}
#endif // !defined(_LIBCPP_CXX03_LANG)
#endif // !defined(_LIBCPP_CXX03_LANG)
} // std
} // namespace std
#endif // _LIBCPP_INITIALIZER_LIST
#endif // _LIBCPP_INITIALIZER_LIST