Some pseudo code and notes on AST implementation