re-implement lambdas
This commit is contained in:
@@ -352,7 +352,7 @@ where
|
|||||||
Ok(Value::Nil)
|
Ok(Value::Nil)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
ParseTree::LambdaDefinition(func) => todo!(),
|
ParseTree::LambdaDefinition(func) => Ok(Value::Function(func)),
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -413,7 +413,7 @@ mod tests {
|
|||||||
|
|
||||||
#[test]
|
#[test]
|
||||||
fn uwu() {
|
fn uwu() {
|
||||||
let program = ":. add x y + x y";
|
let program = ": id ?. x Any -> Any x id 5";
|
||||||
|
|
||||||
let tokens: Vec<Token> = Tokenizer::from_str(program).unwrap().collect::<Result<_, TokenizeError>>().unwrap();
|
let tokens: Vec<Token> = Tokenizer::from_str(program).unwrap().collect::<Result<_, TokenizeError>>().unwrap();
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user