In computer science, a symbol table is a data structure used by a language translator such as a compiler or interpreter, where each identifier in a program’s source code is associated with information relating to its declaration or appearance in the source, such as its type, scope level and sometimes its location.
A high-level view of the front-end of CPython is:
- Parse source code into a parse tree
- Transform parse tree into an Abstract Syntax Tree
- Transform AST into a Control Flow Graph
- Emit bytecode based on the Control Flow Graph
No comments:
Post a Comment