mirror of
https://github.com/github/semantic.git
synced 2024-12-01 09:15:01 +03:00
Recover from errors naïvely.
This commit is contained in:
parent
754e7c1e1c
commit
6b5c78160e
@ -117,7 +117,7 @@ instance (Enum symbol, Ord symbol, Show symbol) => Assigning symbol (Assignment
|
|||||||
NotNullable -> NotNullable)
|
NotNullable -> NotNullable)
|
||||||
(firstSet a)
|
(firstSet a)
|
||||||
(map (fmap (\ match src state follow -> case match src state follow of
|
(map (fmap (\ match src state follow -> case match src state follow of
|
||||||
Left err -> Left err
|
Left err -> Right (advanceState state, termIn (stateLocation state) (inject (Syntax.errorSyntax (either id show <$> err) [])))
|
||||||
Right (state', syntax) -> Right (state', termIn (stateLocation state) (inject syntax)))) (choices a))
|
Right (state', syntax) -> Right (state', termIn (stateLocation state) (inject syntax)))) (choices a))
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user