The top-level of the package defines four functions. If you import compiler, you will get these functions and a collection of modules contained in the package.
buf) |
path) |
parse(open(path).read())
.
ast, visitor[, verbose]) |
source, filename, mode, flags=None, dont_inherit=None) |
The filename will be used for run-time error messages.
The mode must be 'exec' to compile a module, 'single' to compile a single (interactive) statement, or 'eval' to compile an expression.
The flags and dont_inherit arguments affect future-related statements, but are not supported yet.
source) |
The compiler package contains the following modules: ast, consts, future, misc, pyassem, pycodegen, symbols, transformer, and visitor.
See About this document... for information on suggesting changes.