Buffer.resizeRange

bool resizeRange(uint idx, int length, ptrdiff_t offset, ptrdiff_t size)

Sets the total size of the length memory blocks starting at idx in buffer

Parameters

idxan index
lengtha length
offsetthe offset adjustment
sizethe new size or -1 to just adjust the offset

Returns

true if resizing succeeded, false otherwise.