-
Notifications
You must be signed in to change notification settings - Fork 3.3k
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
Semantic predicates prevent fallback to full-context parsing #32
Comments
If we have 3 alts with predicates and they are all ambig in local context but alt 1 is eliminated in full ctx parse. but, we choose first alt with local ctx. we don't check full ctx parse first. Not sure what to do. maybe just doc it ;) |
Local/full context handling is independent of semantic context handling. If the presence of semantic contexts prevents the fallback to full context parsing, then using an LR rule in a grammar could turn an otherwise LL() parser into an SLL() parser, undoing one of ANTLR 4's most significant contributions. |
This issue is simply not correct. The parser does fall back to full context parsing even when semantic predicates are present. |
Fix import statements under Python 3.2
Leave spaces alone unless escaped spaces requested
replaced CodePointCharStream with StringCharStream closes antlr#31
Currently full-context parsing is prevented when one or more configs contain semantic predicates. However, full-context parsing may eliminate one or more configs before the predicate evaluation stage which could change the predicted alternative.
The text was updated successfully, but these errors were encountered: