Converting AST Objects

AST objects, regardless of the input used to create them, may be converted to parse trees represented as list- or tuple- trees, or may be compiled into executable code objects. Parse trees may be extracted with or without line numbering information.


\begin{funcdesc}{ast2list}{ast\optional{\, line_info\code{ = 0}}}
This function ...
...ken. This information is omitted if the flag is
false or omitted.
\end{funcdesc}


\begin{funcdesc}{ast2tuple}{ast\optional{\, line_info\code{ = 0}}}
This function...
...ken. This information is omitted if the flag is
false or omitted.
\end{funcdesc}


\begin{funcdesc}{compileast}{ast\optional{\, filename\code{ = '<ast>'}}}
The Pyt...
...an be diagnosed programmatically by
inspection of the parse tree.
\end{funcdesc}