by victorNicollet · 3y ago · 0 comments
But if a parser combinator library may support converting the resulting combined parser into an eBNF grammar, and check whether that grammar contains conflicts.
IF you are using a 'functional' paradigm, you can do your own parser/combinator.
But if you are using C#, you use something like Yacc and LR.?
Are you concerned with the documentation getting out of sync with the actual language?
To give a very ugly example, if you have a language with function calls f(expr, expr, expr) and you want to add tuple syntax to expressions with a brand new rule:
expr := expr COMMA expr
Then you might have accidentally turned all functions into unary functions, as the tuple rule captures the "expr, expr, expr" part and leaves you with f(expr).