Skip to content

Commit

Permalink
Fix Bogdanp#7 - parse destructuring in lambda expression
Browse files Browse the repository at this point in the history
  • Loading branch information
tunguski committed Apr 18, 2017
1 parent a6db605 commit 977399f
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/Ast/Expression.elm
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ type Expression
| If Expression Expression Expression
| Let (List LetBinding) Expression
| Case Expression (List (Expression, Expression))
| Lambda (List Name) Expression
| Lambda (List Parameter) Expression
| Application Expression Expression
| BinOp Expression Expression Expression

Expand Down Expand Up @@ -144,7 +144,7 @@ lambda : OpTable -> Parser s Expression
lambda ops =
lazy <| \() ->
Lambda
<$> (symbol "\\" *> many (between_ spaces loName))
<$> (symbol "\\" *> many (between_ spaces functionParameter))
<*> (symbol "->" *> expression ops)

{- Parse function application.
Expand Down

0 comments on commit 977399f

Please sign in to comment.