1
1
Fork 0
mirror of https://github.com/azur1s/bobbylisp.git synced 2024-10-16 02:37:40 -05:00

Update lib.rs

This commit is contained in:
Natapat Samutpong 2022-03-10 14:50:46 +07:00
parent 7f28b2f8df
commit 0743717ce5

View file

@ -69,13 +69,15 @@ fn expr_parser() -> impl Parser<Token, Vec<Spanned<Expr>>, Error = Simple<Token>
) )
.repeated() .repeated()
) )
.foldl(|name, args| {( .foldl(|name, args| {
(
Expr::Call { Expr::Call {
name: Box::new(name.clone()), name: Box::new(name.clone()),
args: (args, name.1.clone()), args: (args, name.1.clone()),
}, },
name.1, name.1,
)}); )
});
let unary = choice(( let unary = choice((
just(Token::Plus), just(Token::Plus),