Repository navigation
Parser forgets to check every alteration sometimes. #459
Closed
simon-glitch
started this conversation in
General
Replies: 2 comments 1 reply
|
Ah, i think i found the issue. The parser gets too greedy. For example, |
0 replies
|
Yes, Ohm works in a way that's fundamentally different than some other tools you might have used in the past. It's based a formalism called parsing expression grammars. The main differences are exactly as you describe:
The latter is mentioned on the Patterns & Pitfalls page, but I see now that the tutorial doesn't mention these things! It's probably worth adding. |
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
I have this code for a Rule:
And the parser is not checking
Value_FunctionnorValue_String.Value_Expressionleads it to the end of the string and the parser forgets that it could useValue_FunctionorValue_Stringinstead ofValue_Function nor Value_Expression. I have a part ofValue_Expressionthat includesend. Am I supposed to avoid usingendor something?Here is the full Grammar file (in case it is helpful; yes, I know it is long):
All reactions