Skip to content
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

Add example of parsing using a different starting rule #155

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

ryanprior
Copy link

After digging in the doc strings to find out how to parse using a different starting rule, I added a hint to the README.

README.rst Outdated Show resolved Hide resolved
@@ -55,6 +55,8 @@ Next, let's parse something and get an abstract syntax tree:
<Node called "bold_open" matching "((">
<RegexNode called "text" matching "bold stuff">
<Node called "bold_close" matching "))">
>>> print grammar['text'].parse('other stuff')
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this should be removed. It clutters up the simple use case example. Once the documentation is expanded then we can better document use cases like this.

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please remove this.

Co-authored-by: evanh <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants