ludic.base: tb_reserve and imap_reserve size a table up front; HandlePool (a slot and a generation, nothing made after hd_pool_new, past its capacity a panic naming it); kept_push is the one declared grow, and every growth path left says its bound in @alloc_ok
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
parent
f2dd27f443
commit
2d1d06899e
17 changed files with 199 additions and 26 deletions
|
|
@ -34,6 +34,7 @@ function sb_same(sb: StrBuf, s: string) -> bool {
|
|||
}
|
||||
|
||||
# the table's string for the buffer's bytes
|
||||
@alloc_ok("intern: one string per distinct text, up to the table's most, then kept")
|
||||
export function sb_intern(sb: StrBuf, tb: StrTable) -> string {
|
||||
let h = sb_hash(sb)
|
||||
let mask = len(tb.hs) - 1
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue