Expand description
tatara-eval — an optimized in-memory Lisp interpreter.
Takes Sexp from tatara-lisp, evaluates to Value. Produces typed
Derivation values via the derivation builtin, which tatara-nix::realize
then builds into concrete store paths (either our own store or the live
/nix/store on disk).
source ──read──► Sexp ──eval──► Value
│
▼ (if Derivation)
tatara-nix::realize
│
▼
StorePathThe interpreter is Rust-bordered (you get a typed Derivation or a typed
error, never a partially-built thing), Lisp-authorable, and cheap to
clone thanks to Arc-backed Value cells. A future &'arena form can
replace the Arcs without changing the public API.
Re-exports§
pub use env::Env;pub use error::EvalError;pub use error::Result;pub use interpreter::Interpreter;pub use system::system_builtin_table;pub use value::Arity;pub use value::Builtin;pub use value::Lambda;pub use value::Thunk;pub use value::ThunkState;pub use value::Value;
Modules§
- builtins
- Builtin functions — the thin standard library exposed to the interpreter.
- env
- Scoped environment — parent-pointer tree of bindings.
- error
- Evaluator errors — cover unknown identifiers, type mismatches, arity mismatches, and propagated reader/macroexpander errors from tatara-lisp.
- interpreter
- Tree-walking interpreter —
Sexp→Value. - system
- Opt-in system builtins for the interpreter.
- value
Value— runtime values produced by the interpreter.