ref: 12c9d2fc728b51aa1eb9a70d0d331eb9464912d9
dir: /src/htable.h/
#pragma once #define HT_N_INLINE 32 typedef struct { void **table; int size; // this is to skip over non-items in for-each // FIXME(sigrid): in a multithreaded environment this isn't enough int i; void *_space[HT_N_INLINE]; }sl_aligned(8) sl_htable; // define this to be an invalid key/value #define HT_NOTFOUND ((void*)1) // initialize and free sl_htable *htable_new(sl_htable *h, int size); void htable_free(sl_htable *h); // clear and (possibly) change size void htable_reset(sl_htable *h, int sz);