I am trying to do another thing that is probably straightforward but is giving me a lot of problems:
I need a DSL statement to generate code in two places in the output: at the top of the main method for initialization, and within an infinite loop for use. I can use a COPY_SRC macro for one of them, but generating the second one is harder. I am guessing that I must use a weaving rule, but whenever I try to attach a mapping label to a block statement or the loop itself and try to use it, I get messages that say things along the lines of "no child role statement known for... source node's... BlockStatement concept".
I must be misunderstanding what I am supposed to be labeling, and how to tell the weaving rule where to place the node. Can someone help with an explanation?
I saw another question on the forum along these lines, but the answer suggested looking at the generator demos, which I have completed. They did not clarify the matter for me. Numerous experiments also have yet to succeed.
Could someone shed more light on this?