Skip to content

Latest commit

 

History

History
22 lines (17 loc) · 684 Bytes

README.md

File metadata and controls

22 lines (17 loc) · 684 Bytes

minipython compiler

This is a compiler built using SableCC for a subset of the Python Language called minipython

Run Instrustions

To generate the minipython package using the grammar file use the following command:

sablecc minipython.grammar

The minipython package is already included in this repository

To run some tests included in the example.py use the following commands:

javac ParserTest.java
java ParserTest example.py

Before you run the example tests, remove the comments for each test case you want to test

BNF

Below is the BNF for the minipython language

Image