|Re: [XPand2] setting local variables [message #805893 is a reply to message #805869]
||Fri, 24 February 2012 09:09
| Karsten Thoms
Registered: July 2009
The LET statement binds the result of an expression to a variable. There is no concept in Xpand to define variables, and usually it is not needed.|
Anyway, to come around this you could use the elementprops extensions from stdlib.
You should always ask yourself: Do I really need this? I do not know your usecase, but it is likely that you could come around your issue with a smarter use of extension functions for your template. I have programmed so many templates, and don't have a real need for local variables in 99%. Also I avoid to use LET in favor of extension functions whenever applicable.
Need professional support for Xtext, Xpand, EMF?
Go to: http://xtext.itemis.com
Twitter : @kthoms
Blog : www.karsten-thoms.de
Powered by FUDForum
. Page generated in 0.01581 seconds