Skip to content

Latest commit

 

History

History
23 lines (21 loc) · 704 Bytes

File metadata and controls

23 lines (21 loc) · 704 Bytes

PPL

Compile simplified C-Language into Java Code

About

I took the course Principles Of Programming Languages during my Exchange Semester at the Ho Chi Minh University of Technology, Vietnam. The goal of the course is to build a compiler which translates MC, a simplified version of C, into Java using ANTLR4 and Python 3.4.

Content

Assignment 1: Lexer & Parser

write MC Grammar to create Parse Tree

  • MC.g4
  • LexerSuite.py
  • ParserSuite.py

Assignment 2: AST Generation

create an Abstract Syntax Tree

  • ASTGeneration.py
  • ASTGenSuite.py

Assignment 3: Static Checker

implement static type and name checking

  • StaticCheck.py
  • CheckSuite.py

Assignment 4: Code Generation

tbc