ludic.compass: the marks' pools made with the state (512), compass_at's empty mark kept; ludic.base imap_clear in place; ludic.things' kept lists through kept_push; ludic.net's once-per-room and STUN log lines declared

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
Orkun ÇAKILKAYA 2026-09-28 16:22:48 +03:00
parent 8dfcccad41
commit d3911d4ba8
11 changed files with 40 additions and 19 deletions

View file

@ -67,7 +67,12 @@ export function imap_del(m: IntMap, k: int) -> bool {
}
export function imap_len(m: IntMap) -> int { return m.n }
export function imap_clear(m: IntMap) -> void { imap_alloc(m, m.mask + 1) }
# every key gone, in place: the arrays are kept at the size they grew to
export function imap_clear(m: IntMap) -> void {
for i in 0 .. len(m.keys) { m.keys[i] = -1 }
m.n = 0
m.used = 0
}
# room for `n` keys before the map grows, made now
export function imap_reserve(m: IntMap, n: int) -> void {