Should something like this be possible?
macro {
var test: ${macro: ?String} = null;
}
It seems like that should work, but it doesn't.
The actual use case involved dynamically creating anonymous types.
I'm currently doing this through string concatenatin, but it's pretty ugly:
exprs.push("var test: {" +
list.map(function(test): String return '${test.name}: ${test.type}').join(", ") +
"} = {" + list.map(function(test): String return '${test.name}: null').join(", ") + "}");
Or at least something similar to that.
Later on:
Context.parse(expr, Context.currentPos());
Thanks!