3#define TABLE_SZ(sz) (sizeof(struct SymTable_) + sz * SZ_INT)
21 for (
uint i = ht->
sz + 1; --i;) {
35 strcpy(s->
name, name);
45 if (!strcmp(sym->name, name))
return sym;
49 return ht->
sym[index];
meta header (use this to include the whole library)
ANN unsigned int hash(const m_str s0)
#define mp_free2(p, sz, a)
#define mp_malloc2(p, sz)
static Symbol mksymbol(MemPool p, const m_str name, const Symbol next)
static ANN void free_symbol(MemPool p, const Symbol s)
ANN void free_symbols(SymTable *const ht)
ANN SymTable * new_symbol_table(MemPool p, const size_t sz)
ANN Symbol insert_symbol(SymTable *const ht, const m_str name)
static ANN int gwt_unlock(gwtlock_t *lock)
static ANN void gwt_lock_end(gwtlock_t *lock)
static ANN int gwt_lock_ini(gwtlock_t *lock)
static ANN int gwt_lock(gwtlock_t *lock)