symtab.h

来自「SIP软件开发记录 由于通信网的封闭性」· C头文件 代码 · 共 36 行

H
36
字号
/* symtab.h
 * Symbol table interface for the TINY conpiler
 * (allows only one symbol table)
 *执行与T I N Y应用相符的符号表的杂凑表
 * Compiler Construction: Principles and Practice
 * Kenneth C. Louden
 * 编译原理及实践
 * (美) Kenneth C. Louden 著
 * 冯博琴 冯岚 等译
 * 机械工业出版社 IBSN 7-111-07703-2
 * 源代码:zwf编辑并修订
 * Code Modify: Larry Li 2001.11
 */
#ifndef _SYMTAB_H_
#define _SYMTAB_H_

/* Procedure st_insert inserts line numbers and
 * memory locations into the symbol table
 * loc = memory llocation is inserted only the
 * first time, otherwise ignored
 */
void st_insert(char *name, int lineno, int loc);

/* Function st_lookup returns the memory
 * loaction of a variable or -1 if not found
 */
int st_lookup(char *name);

/* Procedure printSymTab prints a formatted
 * listing of the symbol table contents
 * to the listing file
 */
void printSymTab(FILE * listing);

#endif							/* _SYMTAB_H_ */

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?