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

Question: is there a way to obtain the # of tokens in the matched expression without building a parse tree? #107

Open
eilonreshef opened this issue Jan 21, 2017 · 0 comments

Comments

@eilonreshef
Copy link

E.g., using parboiled to parse a continuous stream and look for certain patterns (e.g., calculator)

e.g.,
A B C D 2 + 3 F G H I
we're parsing every prefix (ABC..., BCD..., CD2...)
and would like to be able to tell that the matched expression 2 + 3 has 3 tokens (without building the tree)

parseTree.end - parseTree.start gives us the result but requires building of the tree

Thanks

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

No branches or pull requests

1 participant