Extending a generator of an existing language to generate new artefacts

Hello !

I am new to MPS and recently tried some examples at creating languages and generating code or xml. Its very easy to start from scratch but, to extend i get confused.

What i want to do now is to extend a language which already generates some code and add a new generator that generates some other artefacts using the same structure in the parent language. I want a user of my language to use my extended language and get both the artefacts. (old language + new language)

Is this possible ? How can we do this...

 

Many thanks in advance..

 

1 comment

 

Step 1

Step 2

Step 3:

If you want to inherited the generator then choose Extend otherwise if you just want to change the priority choose Design.

Note :  While extending a generator make sure your generator is run before the extended one - give it higher priority in the generator order priority dialog. You can get the details about how to set the generator plan from this link https://confluence.jetbrains.com/display/MPSD33/Generator

0

Please sign in to leave a comment.