1
0
Fork 0

Codechange: Removed SmallVector::Assign()

pull/7419/head
Henry Wilson 2018-09-25 20:44:39 +01:00 committed by PeterN
parent 5795f66d2e
commit bc7dcaffca
1 changed files with 1 additions and 12 deletions

View File

@ -60,23 +60,12 @@ public:
template <uint X> template <uint X>
SmallVector &operator=(const SmallVector<T, X> &other) SmallVector &operator=(const SmallVector<T, X> &other)
{ {
this->Assign(other); std::vector<T>::operator=(other);
return *this; return *this;
} }
~SmallVector() = default; ~SmallVector() = default;
/**
* Assign items from other vector.
*/
template <uint X>
inline void Assign(const SmallVector<T, X> &other)
{
if ((const void *)&other == (void *)this) return;
std::vector<T>::operator=(other);
}
/** /**
* Append an item and return it. * Append an item and return it.
* @param to_add the number of items to append * @param to_add the number of items to append