JetBrains MPS Shapes tutorial error -
i've been following jetbrains mps shapes tutorial: https://confluence.jetbrains.com/display/mpsd32/shapes+-+an+introductory+mps+tutorial
in tutorial section "a more robust generation squares" there following definition:
template reduce_square input square parameters << ... >> content node: { graphics g = null; <tf { ->$g.setcolor(color.->$red); ->$g.drawrect($10, $10, $10, $10); } tf> }
and reference macro g (which can see in inspector part of editor if put cursor @ ->$g) is:
(outputnode, gencontext, operationcontext, node)->join(node<variabledeclaration> | string) { gencontext.get output graphicparam (node.parent : canvas); }
yet when trying rebuild "shapes" language following error message (4 times, twice each ->$g):
type node<> not subtype of node<variabledeclaration>
could please check specify , concepts mapping label correctly? should "label graphicsparam : canvas -> parameterdeclaration", specified in tutorial.
Comments
Post a Comment