The project didn't work out well but the knowhow stayed. It helps to just realize that everything is just AST nodes, so ultimately your task always boils down into 5 steps: 1) Figure out the AST pattern of the code you want to generate (there was a proc for printing that out whose name eludes me. The docs on macros also give plenty examples how various pieces of syntax boil down to specific NimNode patterns) 2) Figure out what you want the syntax to look like that the user inputs 3) Write a proc that converts the input NimNode to your desired Output 4) Use that proc in your macro 5) Add validation of the input for helpful error messages when expected input syntax is wrong + ensure the structure that generates your code is understandable. Doc comments, doc comments, doc comments.