You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I don't believe so; our implementation of <||> uses try on the first parser, which says "if you fail, restore the input state to what it was before you consumed any input". From what I can tell, choice does not restore the input state after failure.
Thinking about this a bit more, this will actually only effect you if any of the strings you're attempting to parse with the parsers given to choice consume inputs that share a prefix... I think if all the options are common-prefix-free, you should be totally fine to use choice instead of chained uses of <||>.
Is
choice
a comparable option instead of<||>
?https://hackage.haskell.org/package/parsec-3.1.14.0/docs/Text-Parsec-Combinator.html
The text was updated successfully, but these errors were encountered: