Elektrine lite

← Feed

@cda@macaw.social

Post #2937849

2026-05-13 22:21 UTC

@lritter@mastodon.gamedev.place oh interesting! I was toying with supporting slices. Thought only briefly about a special allocator just for strings or not...or schemes like un-special allocation but manage chunk-sized allocations sort of like gap-buffers so prepending and appending strings is free-or-cheap within some bounds.

Replies (1)

  • @cda@macaw.social yeh. archeap allocs are all pow2 sized, so reallocs have the same footprint as dynamic arrays - in fact, i just use allocs as dynarrays since alloc size is queryable. when you prepend it grows the front instead bc, as said, shareable (and baseable) offset pointers :)

    Open ##2937850