I have a problem with xtext. Basicly I try to create a whitespace sensitive language. This is what my grammer should allow:
Title
Message
Signal 1
Signal 2
Struct
Signal 3
Signal 4
And this should be not allowed.
Title
Message
Signal 1
Signal 2
Struct
Signal 3
Signal 4
So the problem is that Signal 1 is one level above Signal 2. But going to the next level is only allowed for structs.
I have no plan how to check wether the next line is on the same level or not. Can you give me a hint or a similar code snippet?
Thanks