Is it possible to get context of outer macro?
For example, I have template like this:
$LOOP$[container.add($LOOP$[null])];
Is it possible to get outer $LOOP$ input node inside macro-function of inner $LOOP$?
Thanks.
Please sign in to leave a comment.
Hi,
Add mapping label to the outer macro and use
genContext.get prev input <mapping label>
in inner macro.
see also
http://confluence.jetbrains.net/display/MPS/Generator+Language
section 'Getting Contextual Info'