Rework of translation to maintain AST.