Files
RustAst/src/ast/compiler/mod.rs
T
Michael Schimmel 1b49719d31 feat: Add lambda collection and specialization
Introduces `LambdaCollector` to gather lambda functions and populate the
function registry. This enables the `Specializer` to work with
user-defined functions.

The `Environment` struct is updated to manage the `function_registry`
and `monomorph_cache`, which are essential for the specialization
process.

The `link` method in `Environment` now incorporates lambda collection
and node specialization before applying TCO optimization. This ensures
that lambdas are properly processed and specialized for potential
performance gains.

The `Specializer`'s `new` constructor has been modified to accept and
initialize the `MonoCache` through an `Rc<RefCell<MonoCache>>`. This
allows the cache to be shared across different specialized functions.

Also includes minor refactoring and type adjustments in `specializer.rs`
for better clarity and consistency.
2026-02-19 22:26:24 +01:00

19 lines
355 B
Rust

pub mod binder;
pub mod bound_nodes;
pub mod tco;
pub mod upvalues;
pub mod dumper;
pub mod macros;
pub mod type_checker;
pub mod specializer;
pub mod lambda_collector;
pub use binder::*;
pub use bound_nodes::*;
pub use tco::*;
pub use upvalues::*;
pub use dumper::*;
pub use macros::*;
pub use type_checker::*;
pub use specializer::*;