4 OBJECT
symtbl_new(STATE
);
5 OBJECT
symtbl_lookup(STATE
, OBJECT self
, OBJECT string
);
6 OBJECT
symtbl_lookup_cstr(STATE
, OBJECT self
, const char *str
);
7 OBJECT
symtbl_lookup_str_with_size(STATE
, OBJECT self
, const char *str
, int size
);
8 OBJECT
symtbl_find_string(STATE
, OBJECT self
, OBJECT sym
);
9 OBJECT
symbol_to_string(STATE
, OBJECT self
);
11 #define symbol_from_cstr(st, str) symtbl_lookup_cstr(st, st->global->symbols, str)
12 #define SYM(str) symtbl_lookup_cstr(state, state->global->symbols, str)
14 static inline OBJECT
symbol_from_index(STATE
, size_t idx
) {
15 return DATA_APPLY_TAG(idx
, DATA_TAG_SYMBOL
);
18 static inline size_t symbol_to_index(STATE
, OBJECT self
) {
19 return DATA_STRIP_TAG(self
);