mirror of
https://github.com/github/semantic.git
synced 2024-12-24 15:35:14 +03:00
Pull the rhs into a where clause.
This commit is contained in:
parent
28404ae11e
commit
b80dd5381a
@ -53,7 +53,8 @@ expr :: (TokenParsing m, Monad m) => m (Term Core User)
|
||||
expr = ifthenelse <|> lambda <|> rec <|> load <|> assign
|
||||
|
||||
assign :: (TokenParsing m, Monad m) => m (Term Core User)
|
||||
assign = application <**> (flip (Core..=) <$ symbolic '=' <*> application <|> pure id) <?> "assignment"
|
||||
assign = application <**> (symbolic '=' *> rhs <|> pure id) <?> "assignment"
|
||||
where rhs = flip (Core..=) <$> application
|
||||
|
||||
application :: (TokenParsing m, Monad m) => m (Term Core User)
|
||||
application = projection `chainl1` (pure (Core.$$))
|
||||
|
Loading…
Reference in New Issue
Block a user