|
18.1.6.1 Emulation of compile()While many useful operations may take place between parsing and bytecode generation, the simplest operation is to do nothing. For this purpose, using the parser module to produce an intermediate data structure is equivalent to the code
The equivalent operation using the parser module is somewhat longer, and allows the intermediate internal parse tree to be retained as an AST object:
An application which needs both AST and code objects can package this code into readily available functions:
See About this document... for information on suggesting changes. |