-
Notifications
You must be signed in to change notification settings - Fork 233
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Parsing Markdown Lists #243
Comments
Duplicate of #89. The problem is the same: prefer
In this example, each list must be followed by a line, so it can't be followed by another list. |
@deltaidea Thanks for the reply, your example code is not only correct but also really informative! Using Also, you linked to #89 but @introrse said "I modified nearley.js" to get his example working, so maybe others should look here for how to solve (unless there is a difference between the two problems that I'm not getting) |
Thanks for helping out with this, @deltaidea. And glad we could solve your problem, @techpines! |
I'm trying to parse markdown lists, where you create a list using
*
like so:Here's my grammar, where I'd like to have those list lines grouped together unambiguously into one object:
My problem is that this grammar is ambiguous because you can group the list lines
* List Item
a couple of different ways. I want all the list items grouped together, but I'm not sure how to force this and make my grammar unambiguous. Or maybe I'm just solving this problem completely wrong ;)Slight side note, I assume the example text starts with a
"\n"
to make the grammar easier to parse.Any help would be greatly appreciated, thanks!
The text was updated successfully, but these errors were encountered: