Skip to content

Commit dbc7d28

Browse files
committed
Use replace_empty_allocation in bounded_vector's copy assignment operator
1 parent 68b2703 commit dbc7d28

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

source/containers/bounded_vector.cpp

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -124,8 +124,7 @@ struct [[clang::trivial_abi]] bounded_vector : private lexicographical_compariso
124124
}
125125
if constexpr (min_capacity > 0_bi) {
126126
if (!m_storage.data()) {
127-
BOUNDED_ASSERT(m_size == 0_bi);
128-
m_storage.replace_allocation(reservation_size(other.size()));
127+
replace_empty_allocation(other.size());
129128
::containers::uninitialized_copy_no_overlap(other, data());
130129
m_size = other.m_size;
131130
return *this;

0 commit comments

Comments
 (0)