GC.expandArrayUsed
bool expandArrayUsed(void[] slice, size_t newUsed, bool atomic = false) nothrow @safeExpand the array used size in place.
Used for appending and expanding the length of the array slice. If the operation can be performed without reallocating, the function succeeds. Newly expanded data is not initialized. Slices that do not point at expandable GC blocks cannot be affected, and this function will always return false.
Parameters
slice | the slice to attempt expanding in place. |
newUsed | the size that should be stored as used. |
atomic | if true, the array may be shared between threads, and this operation should be done atomically. |
Returns
true if successful.