|LL(*)-left refactoring and cross-reference [message #1017161]
||Sun, 10 March 2013 06:14
| Vincent Simonet
Registered: March 2013
I've a language (lesscss) that requires a grammar entry like:
ident=IDENT term=Term 'set'
| reference=[VariableCrossReference|IDENT] term=Term 'get'
where Term is a recursive rule.
This rule is rejected by ANTLR because has non-LL(*) decision due to recursive rule invocations (in short, you need to parse 'set' or 'get' to decide between the first and the second alternative.
The usual way to resolve the issue with LL(*) grammars would be to make a left refactoring like:
ident=IDENT term=Term keywork=('set | 'get')
but I cannot do that with Xtext and keep the cross-reference.
Is there a way to workaround this limitation?
Powered by FUDForum
. Page generated in 0.01587 seconds