This is a not-so-efficient implementation for a compiler for a very basic language developed as part of a university course. To view the rules of the language and the complete problem statement, please refer to the problem statement. The code implements:
- Grammar and grammar parser
- Tokeniser
- Lexer
- Type expression table generator
- Type errors generator
git clone https://github.com/sarthak-sehgal/dummy-compiler
cd toy-compiler
make run && ./output t1.txt
Note: t1.txt is a sample source code file. The argument can be replaced by any other file (eg: make run && ./output your_source_code.txt
)