| Crates.io | lamb |
| lib.rs | lamb |
| version | 0.1.0 |
| created_at | 2023-01-23 16:01:56.951226+00 |
| updated_at | 2023-01-23 16:01:56.951226+00 |
| description | Pure untyped lambda calculus in safe Rust. |
| homepage | |
| repository | https://github.com/Carnagion/lamb |
| max_upload_size | |
| id | 765927 |
| size | 56,900 |
lamb is an implementation of the pure untyped lambda calculus in modern, safe Rust.
Add lamb as a dependency in Cargo.toml:
[dependencies]
lamb = "0.1.0"
The Cargo features repl and prelude can also be enabled to interface with the REPL and prelude:
[dependencies]
lamb = { version = "0.1.0", features = ["repl", "prelude"] }
Install lamb through Cargo:
cargo install lamb
Default:
With prelude enabled:
With repl enabled:
λ> (λx. x) (w z)
Info: Reduced 1 times
w z
λ>
λ> id = λx. x; const = λx y. y;
Info: Binding id added
Info: Binding const added
λ>
λ> :limit 1024
Info: Reduction limit set to 1024
λ> :limit
Info: Current reduction limit is 1024
λ>
λ> :exit