Generation: Non-Template Consequence?

I have a generation transformation that can't easily be expressed as a template.  I'm able to make it work with a template that has nothing in it but a MAP_SRC node that calls my custom code, but I feel like it would be better to have a custom consequence that explicitly calls a method somewhere. 

Is this possible? Like, can I create my own subconcept of RuleConsequence and somehow get the generation language to do what I want?

Thanks,

Daniel.

1 comment

It's not possible to extend RuleConsequence. There are still 2 active approaches, interpreted and compiled templates, and a new RuleConsequence would require a support in the interpreter part, which is not extensible piece of MPS core.

It seems you may also use $INSERT$ macro, with a query function that invokes your code. 

0

Please sign in to leave a comment.