📄 symboltable.h
字号:
/**************************************************************************** * File name: symbolTable.h * * Description: header file for symbolTable.c * * Input: none * * Output: none * * Author: Luojian Chen * * Date: April 16, 1997 * ****************************************************************************/#ifndef _SYMBOL_TABLE_H_#define _SYMBOL_TABLE_H_#include <stdio.h>#include <string.h>#include "decafc.h"#define SYMBOL_TABLE_SIZE 19#define EOS '\0' /* NULL character *//* data structure of one element in the symbol table */typedef struct element { String id; /* key id */ int offset; struct element *typePtr; /* pointer to the type infomation */ struct element *next; /* pointer to the next symbol with the same hash table index */} Element;typedef Element *ElementPtr;typedef ElementPtr HashTableEntry;typedef HashTableEntry *HashTable;/* data structure of the symbol table */typedef struct symbolTable { HashTable hashTable; /* hash table pointer */ int numberOfEntries; /* hash table size */} SymbolTable;typedef SymbolTable *SymbolTablePtr;typedef struct symbolTableStackEntry { SymbolTablePtr symbolTablePtr; int beginLocalVarID; struct symbolTableStackEntry *next;} SymbolTableStackEntry;typedef SymbolTableStackEntry *SymbolTableStackEntryPtr;typedef struct symbolTableStack { SymbolTableStackEntryPtr top;} SymbolTableStack;typedef SymbolTableStack *SymbolTableStackPtr;#endif
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -