Fully fledged lambdas, along with efficiency tweaks across the ast
This commit is contained in:
parent
b0bd369c1d
commit
8efa1dbaad
10 changed files with 264 additions and 70 deletions
11
src/stl.rs
11
src/stl.rs
|
|
@ -492,6 +492,17 @@ pub fn static_stdlib(syms: &mut SymTable) -> Result<(), String> {
|
|||
},
|
||||
);
|
||||
|
||||
syms.insert(
|
||||
"lambda".to_string(),
|
||||
Symbol {
|
||||
name: String::from("lambda"),
|
||||
args: Args::Lazy(2),
|
||||
conditional_branches: true,
|
||||
docs: decl::LAMBDA_DOCSTRING.to_string(),
|
||||
value: ValueType::Internal(Rc::new(decl::lambda_callback)),
|
||||
}
|
||||
);
|
||||
|
||||
Ok(())
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue