kdl
kdl copied to clipboard
KQL syntax ambiguity
'>' is a valid char for identifiers, so [a>b>c] could be parsed as [prop(a>b>c)] or [prop(a>b) > prop(c)] or [prop(a) > prop(b>c)].
which interpretation is correct?
I think the grammar should be modified to require spaces around comparison and decedent operators.
as far as I can tell, any other solution would require unbounded lookahead, due to situations like [a>b>c > d>e>f>g].