Expand description
§Crusty Lox Interpreter
A complete implementation of the Lox programming language interpreter in Rust, based on Robert Nystrom’s “Crafting Interpreters” book.
§Features
- Full Lox language support (variables, control flow, expressions)
- Interactive REPL mode
- File execution
- Comprehensive error reporting
- Lexical scoping
§Example
ⓘ
use crusty::{Interpreter, Source};
let mut interpreter = Interpreter::new();
let source = Source::new(r#"
var x = 42;
print x;
"#.to_string());
// interpreter.evaluate(source); // Would execute the codeRe-exports§
pub use ast::*;pub use environ::*;pub use error::*;pub use evaluate::*;pub use parser::*;pub use reader::*;pub use tokenize::*;