withRecovery
jamesdbrock opened this issue · 2 comments
jamesdbrock commented
recoverWithwill only fire the recovery parser on a failure, and as for the recovery parser, these things are usually incredibly simple, aggressively so.
Originally posted by @Violet-Codes in #222 (comment)
Already discussed in the above issue, but let's open a separate issue for creating a recoverWith or withRecovery function, because that could be supplied independent of the multiple-error feature.
See https://hackage.haskell.org/package/megaparsec-9.3.0/docs/Text-Megaparsec.html#v:withRecovery
jamesdbrock commented
See also mrkkrp/megaparsec#80
Violet-Codes commented
withRecovery is only going to be a useful notion if you can do something with the errors, i.e. bundle or give context too them.