parsec icon indicating copy to clipboard operation
parsec copied to clipboard

A monadic parser combinator library

Results 47 parsec issues
Sort by recently updated
recently updated
newest added

Currently comments are treated as whiteSpace. This leaves {-# LANGUAGE #-} and other Haskell pragmas out of parsed AST. This proposal is to parse comments as a distinct token `whiteSpace`...

Sometimes space around tokens matters a lot. Take Haskell dot for example. This proposal is to add a parameter to `makeTokenParser` https://github.com/haskell/parsec/blob/38dfc545874dd44c26382d8dd692eb533396c6f5/src/Text/Parsec/Token.hs#L358-L361 which would explicitly specify lexeme options: - consume...

The documentation claims that: > If the character is a newline (\'\\n\') or carriage return (\'\\r\') the line number is incremented by 1. (Specified [here](https://github.com/haskell/parsec/blob/38dfc545874dd44c26382d8dd692eb533396c6f5/src/Text/Parsec/Pos.hs#L108-L110).) But the actual definition does...

https://github.com/haskell/parsec/blob/905bc2e3e1c374934d49e16dc5b7c49bf2c3c815/src/Text/Parsec/Perm.hs#L105 In the documentation for the function `` the text refers to the operator `` when it should be the ``

The `ParsecT` definition is not exported, so I cannot write missing low-level combinators myself, even when I know what I'm doing. Not critical, as there is [`mkPT`](https://hackage.haskell.org/package/parsec-3.1.14.0/docs/Text-Parsec-Prim.html#v:mkPT), but I'd like...

Consider the following code entered in ghci: Parsec.parse (Parsec.many1 Parsec.digit