diff options
| author | Andrew Kelley <andrew@ziglang.org> | 2022-07-10 03:06:05 -0400 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2022-07-10 03:06:05 -0400 |
| commit | b88151e0e1553607cbebc197e1111ec4bf53a595 (patch) | |
| tree | cd4f57feae521500fe4eb99a98a798241256d341 /lib/libcxx/include/__split_buffer | |
| parent | 3f11d1d56d9747de974b00eab1c880bea7972c01 (diff) | |
| parent | f9bf4889264aee387639bb8a35fdf594236b1283 (diff) | |
| download | zig-b88151e0e1553607cbebc197e1111ec4bf53a595.tar.gz zig-b88151e0e1553607cbebc197e1111ec4bf53a595.zip | |
Merge pull request #12001 from ziglang/llvm14
Upgrade to LLVM 14
Diffstat (limited to 'lib/libcxx/include/__split_buffer')
| -rw-r--r-- | lib/libcxx/include/__split_buffer | 13 |
1 files changed, 2 insertions, 11 deletions
diff --git a/lib/libcxx/include/__split_buffer b/lib/libcxx/include/__split_buffer index 901c0374aa..2642cf6fca 100644 --- a/lib/libcxx/include/__split_buffer +++ b/lib/libcxx/include/__split_buffer @@ -17,17 +17,8 @@ _LIBCPP_PUSH_MACROS _LIBCPP_BEGIN_NAMESPACE_STD -template <bool> -class __split_buffer_common -{ -protected: - _LIBCPP_NORETURN void __throw_length_error() const; - _LIBCPP_NORETURN void __throw_out_of_range() const; -}; - template <class _Tp, class _Allocator = allocator<_Tp> > struct __split_buffer - : private __split_buffer_common<true> { private: __split_buffer(const __split_buffer&); @@ -248,7 +239,7 @@ __split_buffer<_Tp, _Allocator>::__construct_at_end(_InputIter __first, _InputIt size_type __old_cap = __end_cap() - __first_; size_type __new_cap = _VSTD::max<size_type>(2 * __old_cap, 8); __split_buffer __buf(__new_cap, 0, __a); - for (pointer __p = __begin_; __p != __end_; ++__p, ++__buf.__end_) + for (pointer __p = __begin_; __p != __end_; ++__p, (void) ++__buf.__end_) __alloc_traits::construct(__buf.__alloc(), _VSTD::__to_address(__buf.__end_), _VSTD::move(*__p)); swap(__buf); @@ -268,7 +259,7 @@ typename enable_if __split_buffer<_Tp, _Allocator>::__construct_at_end(_ForwardIterator __first, _ForwardIterator __last) { _ConstructTransaction __tx(&this->__end_, _VSTD::distance(__first, __last)); - for (; __tx.__pos_ != __tx.__end_; ++__tx.__pos_, ++__first) { + for (; __tx.__pos_ != __tx.__end_; ++__tx.__pos_, (void) ++__first) { __alloc_traits::construct(this->__alloc(), _VSTD::__to_address(__tx.__pos_), *__first); } |
