Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/lffg/rs-lox
A tree-walk interpreter and a bytecode virtual machine interpreter written in the Rust Programming Language.
https://github.com/lffg/rs-lox
interpreter parser rust
Last synced: 3 months ago
JSON representation
A tree-walk interpreter and a bytecode virtual machine interpreter written in the Rust Programming Language.
- Host: GitHub
- URL: https://github.com/lffg/rs-lox
- Owner: lffg
- License: mit
- Created: 2021-12-08T22:19:31.000Z (almost 3 years ago)
- Default Branch: main
- Last Pushed: 2022-06-16T00:36:25.000Z (over 2 years ago)
- Last Synced: 2024-06-30T10:25:47.045Z (5 months ago)
- Topics: interpreter, parser, rust
- Language: Rust
- Homepage:
- Size: 157 KB
- Stars: 12
- Watchers: 2
- Forks: 2
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Crafting Interpreters in Rust – `rs-lox`
My implementation of the first interpreter presented in "[Crafting Interpreters](https://craftinginterpreters.com/)", by Robert Nystrom.
This repository holds two implementations for the same language. The first one, `tree-lox` implements a tree-based interpreter and the other, `vm-lox` uses a bytecode virtual machine to interpret the code.
### Quick start
This project can by compiled using Cargo. Use the `--project` flag to choose the implementation.
Run an existing file:
```terminal
$ cargo r -p tree-lox -- script-name.lox
```Open the REPL:
```
$ cargo r -p tree-lox
```### Project overview
todo
### License
Code licensed under the MIT license.