#include "ctrump/common/dll.h"
Go to the source code of this file.
Data Structures | |
struct | ctrump_symbol |
symbol More... | |
Functions | |
CTRUMP_EXTDEF struct ctrump_symbol * | ctrump_intern (const char *symstr, int symstrlen) |
get symbol | |
CTRUMP_EXTDEF int | ctrump_get_current_symbol_num (void) |
get current number of symbols. | |
CTRUMP_EXTDEF void | ctrump_init_symtab (int initial_size) |
ctrump_intern()を呼ぶと、シンボルが取得できる ctrump_intern()の引数symstrに同じ文字列を渡すと、 同じポインタが返る
Definition in file symbol.h.
CTRUMP_EXTDEF int ctrump_get_current_symbol_num | ( | void | ) |
get current number of symbols.
Definition at line 125 of file symbol.c.
References symbol_id.
Referenced by env_Init().
CTRUMP_EXTDEF void ctrump_init_symtab | ( | int | initial_size | ) |
Definition at line 68 of file symbol.c.
References ctrump_mempool_init(), and symbol_id.
Referenced by ctrump_init_all().
CTRUMP_EXTDEF struct ctrump_symbol* ctrump_intern | ( | const char * | symstr, | |
int | symstrlen | |||
) | [read] |
get symbol
symstr | charactors (not require zero terminate charactor) | |
symstrlen | length of `symstr' |
Definition at line 88 of file symbol.c.
References ctrump_symbol::chain, ctrump_mempool_alloc, ctrump_mempool_alloc_align(), hash(), ctrump_symbol::hashval, ctrump_symbol::id, symbol_id, ctrump_symbol::symlen, and ctrump_symbol::symstr.
Referenced by build_symbol().