AST generation is usually simple. It's the conversion to the other language that usually get's difficult.