-
Notifications
You must be signed in to change notification settings - Fork 17
/
Analyse.h
40 lines (29 loc) · 1.02 KB
/
Analyse.h
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
27
28
29
30
31
32
33
34
35
36
37
38
39
/*********************************************************************
* NAME: Benjamin Fowler
* NUMBER: 02251132
* SUBJECT: Modern Compiler Construction
* INSTRUCTOR: Dr Wayne Kelly
*********************************************************************
* MODULE: Analyse.h
* PURPOSE: Declares the public portions of the semantic
* analyser module.
* DATE STARTED: 7th May, 2000.
* LAST EDITED: 10th May, 2000.
*********************************************************************/
#ifndef ANALYSE_H
#define ANALYSE_H
#include "Globals.h"
/*
* NAME: buildSymboltable()
* PURPOSE: Takes a syntax tree and traverses it, building a symbol table
* and decorating all identifiers with references to their
* declarations.
*/
void buildSymbolTable(TreeNode *syntaxTree);
/*
* NAME: typeCheck()
* PURPOSE: Traverses the syntax tree and type checks the program.
*/
void typeCheck(TreeNode *syntaxTree);
#endif
/* END OF FILE */