Community
Participate
Working Groups
Considering the following grammar generate myDsl "http://www.xtext.org/example/mydsl/MyDsl" import "http://www.eclipse.org/emf/2002/Ecore" as ecore Model: (disabled?='@Disabled')? 'signal' name=Identifier '{' (((elements+=Element)* (elements2=Element2)?)) '}'; Element2: {Element2} 'element2' '{' (assignments+=Assignment2)* '}'; Assignment2: 'element' numbr=INT '{' (def+=Definition)+ '}'; Definition: someRef=SomeRef '=' (intState=INT) ';'; SomeRef: value=Identifier; Element: 'element' numbr=INT '{' (value=BlaValue? & properties+=PropertyAssignment*) '}'; BlaValue: 'bla' '=' expr=BlaLiteral ';'; BlaLiteral: value=INT; PropertyAssignment: ref=PropertyReference '=' propertyValue=PropertyAssignmentValue ';'; PropertyReference: value=Identifier; Identifier: ID | "xxx"; PropertyAssignmentValue: (negativeValue?='-')? value=(PhysicsQuantityLiteral | StringLiteral); StringLiteral: value=STRING; PhysicsQuantityLiteral: LengthLiteral; LengthLiteral: value=INT unit=Metre; Metre: 'nm' | 'um' | 'mm' | 'm'; and the following model signal x { element 1 { propertyReference = "xxxxx";| } } i dont the the "bla" keyword proposed at the cusor position
(In reply to Christian Dietrich from comment #0) > > i dont the the "bla" keyword proposed at the cusor position Sorry, I didn't get that. What is your expectation and what is the actual result?
i expect to get the keyword bla proposed but the only thing i get is the ; keyword
p.s: i get the "bla" keyword proposed if i insert a blank right after the previos semincolon. but the grammar does not require a space here
(In reply to Christian Dietrich from comment #3) > p.s: > > i get the "bla" keyword proposed if i insert a blank right after the previos > semincolon. but the grammar does not require a space here Got it.