Holy shit i'm stupid

This commit is contained in:
Lynix 2019-09-28 16:55:11 +02:00
parent 489e3e0b5e
commit 89243a39b5
1 changed files with 1 additions and 4 deletions

View File

@ -130,10 +130,7 @@ namespace Nz
PlacementNew(&m_ptr[m_size], std::move(*lastElement));
if (&m_ptr[index] < lastElement)
{
std::size_t count = m_size - index - 1;
std::move_backward(&m_ptr[index], &m_ptr[index + count], &m_ptr[m_size]);
}
std::move_backward(&m_ptr[index], &m_ptr[m_size - 1], &m_ptr[m_size]);
PlacementDestroy(&m_ptr[index]);
}