Complete grammar analysis and AST construction