MCPcopy
hub / github.com/RoaringBitmap/roaring / removeAtIndex

Method removeAtIndex

roaringarray.go:396–403  ·  view source on GitHub ↗
(i int)

Source from the content-addressed store, hash-verified

394}
395
396func (ra *roaringArray) removeAtIndex(i int) {
397 copy(ra.keys[i:], ra.keys[i+1:])
398 copy(ra.containers[i:], ra.containers[i+1:])
399
400 copy(ra.needCopyOnWrite[i:], ra.needCopyOnWrite[i+1:])
401
402 ra.resize(len(ra.keys) - 1)
403}
404
405func (ra *roaringArray) setContainerAtIndex(i int, c container) {
406 ra.containers[i] = c

Callers 6

removeMethod · 0.95
RemoveMethod · 0.45
CheckedRemoveMethod · 0.45
XorMethod · 0.45
FlipMethod · 0.45
RemoveRangeMethod · 0.45

Calls 1

resizeMethod · 0.95

Tested by

no test coverage detected