diff options
-rw-r--r-- | src/Haskell/Parser.hs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/Haskell/Parser.hs b/src/Haskell/Parser.hs index 41216d5..bd10705 100644 --- a/src/Haskell/Parser.hs +++ b/src/Haskell/Parser.hs @@ -79,7 +79,7 @@ pLargePat = choice [PatCon <$> pNameT <*> many pSimplePat pNum :: Parser Integer pNum = (char '-' >> (negate <$> pPositive)) <|> pPositive - where pPositive = read <$> many1 digit + where pPositive = read <$> many1 digit <* aheadW pVariable :: Parser Name pVariable = pName <|> try (parens pOperator) @@ -111,10 +111,10 @@ braces :: Parser a -> Parser a braces = between (symbolBare "{") (symbolBare "}") symbolW :: String -> Parser () -symbolW s = string s >> aheadW +symbolW s = try (string s >> aheadW) symbolO :: String -> Parser () -symbolO s = string s >> aheadO +symbolO s = try (string s >> aheadO) symbolBare :: String -> Parser () symbolBare s = string s >> whitespace |