I would like to reuse grammar definitions.
I have a grammar like this:
Person:
'contact' name=ID '{'
'phone' phone=INT
'}'
;
I would like to have another grammar like this:
include "uri/to/other/project/to/other/grammar/definitions"
Call:
'call' person=Person
;
Person
is not known by the second grammar. Is Xtext therefore able to insert or include the Person
definition from the first grammar into the second grammar?
A further step is the generation of the Person
. I would like to know how to accomplish that too.