add zero() at AutoDeleteArray
This commit is contained in:
parent
0f3ef7ff3f
commit
5d75e138b5
@ -548,6 +548,11 @@ namespace hgl
|
||||
T *begin(){return obj;}
|
||||
T *end(){return obj+size;}
|
||||
|
||||
void zero()
|
||||
{
|
||||
memset(obj,0,size*sizeof(T));
|
||||
}
|
||||
|
||||
T &operator[](int index){return obj[index];}
|
||||
const T &operator[](int index)const{return obj[index];}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user