2
votes

I implemented some AST transformations that are applied at compile time and for logging purposes I would like to emit "source" code that reflects injected AST nodes. The toString()/getText() methods return quite unreadable structure that quickly becomes complicated for long expressions.

1

1 Answers

3
votes

The closest thing I can think of is the AstNodeToScriptAdapter which can be found here