一、符号表结构

 符号表管理——哈工大编译原理课程(四)

二、哈希表的具体结构

 符号表管理——哈工大编译原理课程(四)

三、与符号表相关的函数

int hashpjw(char *s)                散列函数计算

symtbl *mktable(symtbl *bt)         初始化一个符号表,表头before指向bt

void addwidth(symtbl *st,int offset)将offset填入st符号表的表头

int enter(symtbl *st,char *name,int type,int offset,pintqueue piq)

向符号表中增加一条表项

void enterproc(symtbl *st,char *name,symtbl *t) 在st中添加子程序条目

Identifier* lookup(char *name,symtbl* nowsym)   返回name节点在符号表中的指针,如不存在返回null

相关文章:

  • 2021-05-20
  • 2021-04-27
  • 2021-11-13
  • 2022-12-23
  • 2021-04-08
  • 2021-07-29
猜你喜欢
  • 2022-12-23
  • 2021-05-17
  • 2022-12-23
  • 2022-12-23
  • 2022-02-16
  • 2021-09-01
相关资源
相似解决方案