Skip to main content

Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » TMF (Xtext) » Variable Reference or New Variable Declaration
Variable Reference or New Variable Declaration [message #1231043] Mon, 13 January 2014 17:29 Go to next message
Michael Ernst is currently offline Michael ErnstFriend
Messages: 49
Registered: July 2010

I got a grammar which uses some marker element like "var type name" to define new variables. Now I want that I'm also able to write something like "a = 2" without the "var" and "type" elements. So on the left side of an assignment can either be a variable reference or a new variable definition. But how does the grammar looks like if the type "reference" or "variable declaration" depends on the current scope? Any ideas or examples?

Kind regards
Re: Variable Reference or New Variable Declaration [message #1231045 is a reply to message #1231043] Mon, 13 January 2014 17:32 Go to previous message
Christian Dietrich is currently offline Christian DietrichFriend
Messages: 13721
Registered: July 2009
Senior Member

it aint that easy

Need professional support for Xtext, Xpand, EMF?
Go to:
Twitter : @chrdietrich
Blog :

[Updated on: Mon, 13 January 2014 17:32]

Report message to a moderator

Previous Topic:Errors when extending OCL
Next Topic:Xtext grammar translation bug?
Goto Forum:

Current Time: Fri Jan 22 20:39:27 GMT 2021

Powered by FUDForum. Page generated in 0.02005 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top