mirror of
https://github.com/beefytech/Beef.git
synced 2025-06-08 11:38:21 +02:00
Improve POD resize speed
This commit is contained in:
parent
2fded5ab0c
commit
a1fd8d1397
1 changed files with 2 additions and 2 deletions
|
@ -830,8 +830,8 @@ public:
|
|||
else if (size > this->mSize)
|
||||
{
|
||||
Reserve(size);
|
||||
while (size > this->mSize)
|
||||
this->mVals[this->mSize++] = T();
|
||||
memset(&this->mVals[this->mSize], 0, (size - this->mSize) * sizeof(T));
|
||||
this->mSize = (int_cosize)size;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue