- Semester: 242
- Student: Nguyễn Lê Hoàng Phúc
- ID: 2212629
- Lecturer: Master Trần Ngọc Bảo Duy
- Minigo Specification Desiger & Inital source code Provider: PhD Nguyễn Hứa Phùng
These four assignments of Principles of Programming Language subject aim to introduce and guide students to create a simple Compiler based on specification of a new programming language - Minigo. The primary model of Minigo is "Golang" which is an extremely strong and useful language developed by Google.
The project focuses on the fundamental programming language implementation, through five primary stages:
- Lexical Analysis (Assignment 1):
- Use: Regular Expression (ANTLR);
- Self-implementing files: MiniGo.g4, LexerSuite.py.
- Syntax Analysis (Assignment 1):
- Use: Context Free Grammar (ANTLR);
- Self-implementing files: MiniGo.g4, LexerSuite.py.
- Abstract syntax tree Generation (Assignment 2):
- Use: Python;
- Self-implementing files: ASTGeneration.py, ASTGenSuite.py.
- Semantic Analysis (Assignment 3):
- Use: Python;
- Self-implementing files: StaticCheck.py, CheckSuite.py.
- Intermediate code Generation (Assignment 4):
- Use: Python;
- Self-implementing files: CodeGenerator.py, Emitter.py (partial), CodeGenSuite.py.
This result was calculated based on the total number of correct testcases (compared to Author PhD Nguyễn Hứa Phùng):
-
Assigment 1: Lexer(100/100) + Parser (100/100).
-
Assigment 2: 95/100.
-
Assignment 3: 118/125.
-
Assigment 4: 95/101.

