MCPcopy Create free account
hub / github.com/colbymchenry/codegraph / _array__grow

Function _array__grow

codegraph-kernel/grammars/kotlin/tree_sitter/array.h:208–216  ·  view source on GitHub ↗

This is not what you're looking for, see `array_push` or `array_grow_by`.

Source from the content-addressed store, hash-verified

206
207/// This is not what you're looking for, see `array_push` or `array_grow_by`.
208static inline void _array__grow(Array *self, uint32_t count, size_t element_size) {
209 uint32_t new_size = self->size + count;
210 if (new_size > self->capacity) {
211 uint32_t new_capacity = self->capacity * 2;
212 if (new_capacity < 8) new_capacity = 8;
213 if (new_capacity < new_size) new_capacity = new_size;
214 _array__reserve(self, element_size, new_capacity);
215 }
216}
217
218/// This is not what you're looking for, see `array_splice`.
219static inline void _array__splice(Array *self, size_t element_size,

Callers

nothing calls this directly

Calls 1

_array__reserveFunction · 0.70

Tested by

no test coverage detected