I want to create a rule in XText that matches to a string, but does not care in what case the string is. For example, I want it to match against both "DUCK", "DucK" and "duck". Is there a more simple way of doing it than covering all cases, like:
Rule:
'Duck'|'DucK'|'DuCK'|... and so on
;
There is a flag that you can configure in the mwe2 workflow. Replace the
XtextAntlrGeneratorFragment
by theorg.eclipse.xtext.generator.parser.antlr.ex.rt.AntlrGeneratorFragment
and passoptions = { ignoreCase = true }
. Same for theXtextAntlrUiGeneratorFragment
and theorg.eclipse.xtext.generator.parser.antlr.ex.ca.ContentAssistParserGeneratorFragment