nom
nom copied to clipboard
proposal: add a take_until_parser which return consume input until a parser success
here is the reason, when parsing commonmark's code block, it should be delimited by the same length of ` or ~, where we need to keep track of the length of beginning `, and might need to omit ending space. I found it's hard to just use nom to deal with it.
In another parser combinator I used before called sprache(C#) has a Except method to do that thing, I think it might be useful.
I've implemented one in my repo