mirror of
https://github.com/gnustep/libs-base.git
synced 2025-04-22 16:33:29 +00:00
Added remove all items
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@4435 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
fcfe495603
commit
aade319e69
1 changed files with 9 additions and 4 deletions
|
@ -353,16 +353,21 @@ FastArrayClear(FastArray array)
|
|||
}
|
||||
|
||||
static INLINE void
|
||||
FastArrayEmpty(FastArray array)
|
||||
FastArrayRemoveAllItems(FastArray array)
|
||||
{
|
||||
#ifdef FAST_ARRAY_NO_RELEASE
|
||||
array->count = 0;
|
||||
#else
|
||||
#ifndef FAST_ARRAY_NO_RELEASE
|
||||
while (array->count--)
|
||||
{
|
||||
FAST_ARRAY_RELEASE(array->ptr[array->count]);
|
||||
}
|
||||
#endif
|
||||
array->count = 0;
|
||||
}
|
||||
|
||||
static INLINE void
|
||||
FastArrayEmpty(FastArray array)
|
||||
{
|
||||
FastArrayRemoveAllItems(array);
|
||||
FastArrayClear(array);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue