Added a method to reset the memory buffer of the DynArray class.
The the allocated memory will not be touched so the capacity keeps its current level.
This commit is contained in:
@@ -216,6 +216,10 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
void Reset() {
|
||||
_size = 0;
|
||||
}
|
||||
|
||||
void Push( T t ) {
|
||||
EnsureCapacity( _size+1 );
|
||||
_mem[_size++] = t;
|
||||
|
||||
Reference in New Issue
Block a user