Annotating an AST with type checking / source line number info