-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathanalyze.h
More file actions
26 lines (22 loc) · 819 Bytes
/
Copy pathanalyze.h
File metadata and controls
26 lines (22 loc) · 819 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
/****************************************************/
/* File: analyze.h */
/* Semantic analyzer interface for TINY compiler */
/* Compiler Construction: Principles and Practice */
/* Kenneth C. Louden */
/****************************************************/
#ifndef _ANALYZE_H_
#define _ANALYZE_H_
/* Function buildSymtab constructs the symbol
* table by preorder traversal of the syntax tree
*/
void buildSymtab(TreeNode *);
/* Procedure typeCheck performs type checking
* by a postorder syntax tree traversal
*/
void typeCheck(TreeNode *);
void mainVerify();
void traverse(TreeNode *t,
void (*preProc)(TreeNode *),
void (*postProc)(TreeNode *));
extern bool hasAllocations;
#endif