parsec
parsec copied to clipboard
add a parameter to makeTokenParser to specify options for treating space by lexeme
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 trailing space
- do not consume trailing space