Expand description
Tree-walking interpreter for the Virtual Rust VM.
§Architecture
The interpreter is split into focused sub-modules:
| Module | Responsibility |
|---|---|
value | Runtime value types (Value enum) |
environment | Variable scoping (scope stack) |
error | RuntimeError definition |
builtins | Built-in functions & macro dispatch |
methods | Method call dispatch (String, Array, Int, …) |
[format] | Format-string processing ({}, {:?}, {:.2}) |
pattern | Pattern matching for match expressions |
cast | Type casting (as expressions) |
Re-exports§
pub use environment::Environment;pub use error::RuntimeError;pub use value::Value;
Modules§
- builtins
- Built-in function and macro dispatch.
- cast
- Type casting (
asexpressions). - environment
- Variable scoping and environment management.
- error
- Runtime error type for the interpreter.
- format
- Format string processing (
{},{:?},{:.2},{0}, etc.). - methods
- Method dispatch for built-in types.
- pattern
- Pattern matching logic for
matchexpressions. - value
- Runtime value representation for the Virtual Rust interpreter.
Structs§
- Interpreter
- The tree-walking interpreter that evaluates an AST.