AST type expression decoration implementation is not optimal, not elegant!
Actually, everything is in the same AST (localization and expression type).
The best practice is to construct different AST.
In our context, there would be 2 AST :
The typer would take the AST from syntactic analyzer (so with localization) to build a new AST with expression typing, to pass it to the compiler.
AST type expression decoration implementation is not optimal, not elegant! Actually, everything is in the same AST (localization and expression type). The best practice is to construct different AST. In our context, there would be 2 AST : The typer would take the AST from syntactic analyzer (so with localization) to build a new AST with expression typing, to pass it to the compiler.