Open jwaldmann opened 4 years ago
can we make parseExp self-delimiting? The type is
parseExp :: String -> ParseResult (Exp SrcSpanInfo)
but I'd want "maximum munch" and the part that was not eaten, as in :: String -> ParseResult (.. , String)
:: String -> ParseResult (.. , String)
I tried
parseExp "x } foo bar" ParseFailed (SrcLoc "<unknown>.hs" 1 3) "Unexpected }"
so I could extract the error location, and then re-parse that prefix. That's feels a bit strange.
(cf. https://mail.haskell.org/pipermail/haskell-cafe/2020-April/132124.html)
can we make parseExp self-delimiting? The type is
but I'd want "maximum munch" and the part that was not eaten, as in
:: String -> ParseResult (.. , String)
I tried
so I could extract the error location, and then re-parse that prefix. That's feels a bit strange.
(cf. https://mail.haskell.org/pipermail/haskell-cafe/2020-April/132124.html)