Built with guidance from Crafting Interpreters by Robert Nystrom.
Lox interpreter written in Python. Project is nearly complete, but there are issues involved with reassignment within nested scopes. So, currently for loops and many other instances of variable reassignment don't work.
The interpreter has two modes.
- Real Evaluate Print Loop (REPL)
- Usage:
py lox.py
- Enter Lox code and it will be interpreted
- Variables will stay in memory throughout your session
- Enter quit to end the program
- Usage:
- Run a file
- Usage:
py lox.py \<filename\>
- File will be interpreted and run
- Usage:
- To run tests, use
python -m pytest tests/ -vv
- Note, you will need to install pytest to run tests manually