-
Notifications
You must be signed in to change notification settings - Fork 13
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
WIP: Lax parser #8
base: antlr
Are you sure you want to change the base?
Conversation
fb67c09
to
edfa743
Compare
So I found out I can create and UNKNOWN lexer rule that should match everything that hasn't been previously defined.
And that kind of works:
I simplified the grammar to just work on resistors for the time being, trying to figure out why it ignores the
|
We probably should take advantage of
|
That looks like a lexer ambiguity. Try this on the java backend: |
Hmm, it seems to match everything to UNKNOWN so it looks like I was mistaken about how this would work. I wonder how come it kinda half works at all. |
SO answers (1 and 2) seem to suggest that the last lexer rule will be the lowest priority. But that's not what I am seeing. EDIT: Seems the imports re-order things or otherwise mess up the priority. :/ Tracking here: antlr/antlr4#2209 |
No description provided.