Optimize String::ReserveSpace if length doesn't change
This commit is contained in:
@@ -337,6 +337,8 @@ public:
|
||||
void ReserveSpace(int32 length)
|
||||
{
|
||||
ASSERT(length >= 0);
|
||||
if (length == _length)
|
||||
return;
|
||||
Platform::Free(_data);
|
||||
if (length != 0)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user