2

In Xtext 2.0, ML_COMMENT is defined in org.eclipse.xtext.common.Terminals as hidden.

I want to see comments in my grammar.

How can I undo this?

Aaron Digulla
  • 321,842
  • 108
  • 597
  • 820

1 Answers1

4

Just override the hidden statement from the inherited grammar:

grammar org.xtext.example.mydsl.MyDsl 
with org.eclipse.xtext.common.Terminals
hidden(WS, SL_COMMENT)  // <--- Override
Aaron Digulla
  • 321,842
  • 108
  • 597
  • 820
Christian Dietrich
  • 11,778
  • 4
  • 24
  • 32