summaryrefslogtreecommitdiffstats
path: root/libcxx/include/__split_buffer
diff options
context:
space:
mode:
authorEric Fiselier <eric@efcs.ca>2019-12-16 18:23:39 -0500
committerEric Fiselier <eric@efcs.ca>2019-12-16 18:38:58 -0500
commit549545b64aab77d2a1784062451ee1c33f8324d2 (patch)
tree54085e795e52088e247d055f92782ad4e002d2e3 /libcxx/include/__split_buffer
parentf63b64c0c3b486f164c3c66cce9f13df2bac6b6e (diff)
downloadbcm5719-llvm-549545b64aab77d2a1784062451ee1c33f8324d2.tar.gz
bcm5719-llvm-549545b64aab77d2a1784062451ee1c33f8324d2.zip
[libc++] Rework compressed pair constructors.
This patch de-duplicates most compressed pair constructors to use the same code in C++11 and C++03. Part of doing that is deleting the "__second_tag()" and replacing it with a "__value_init_tag()" which has the same effect, but allows for the removal of the special "one-arg" first element constructor. This patch is intended to have no semantic change.
Diffstat (limited to 'libcxx/include/__split_buffer')
-rw-r--r--libcxx/include/__split_buffer4
1 files changed, 2 insertions, 2 deletions
diff --git a/libcxx/include/__split_buffer b/libcxx/include/__split_buffer
index d70c0a7f166..fce209f8287 100644
--- a/libcxx/include/__split_buffer
+++ b/libcxx/include/__split_buffer
@@ -324,7 +324,7 @@ template <class _Tp, class _Allocator>
inline
__split_buffer<_Tp, _Allocator>::__split_buffer()
_NOEXCEPT_(is_nothrow_default_constructible<allocator_type>::value)
- : __first_(nullptr), __begin_(nullptr), __end_(nullptr), __end_cap_(nullptr)
+ : __first_(nullptr), __begin_(nullptr), __end_(nullptr), __end_cap_(nullptr, __default_init_tag())
{
}
@@ -368,7 +368,7 @@ __split_buffer<_Tp, _Allocator>::__split_buffer(__split_buffer&& __c)
template <class _Tp, class _Allocator>
__split_buffer<_Tp, _Allocator>::__split_buffer(__split_buffer&& __c, const __alloc_rr& __a)
- : __end_cap_(__second_tag(), __a)
+ : __end_cap_(nullptr, __a)
{
if (__a == __c.__alloc())
{
OpenPOWER on IntegriCloud