TTCompilerRules
TTCompilerRules
defines how the python abstract syntax tree (AST) library should handle various syntactic elements as it visits each node of the AST.
These rules are automatically called as the ast (abstract syntax tree) library ‘visits’ syntactic structures within the TTPython file to compile.
The TTSQ
constructor is also an especially essential component of the
compilation process!
- class ticktalkpython.CompilerRules.TTGraphCompilationVisitor(graph, debug=False, source=None, pathname=None)
A child class of ast.NodeVisitor, which walks through the ast and calls specific handlers for each syntactic construct
- Parameters:
graph (TTGraph) – An instantiated but empty graph, ready to be filled in as the AST is walked
- ticktalkpython.CompilerRules.import_sqified_functions_from_module(module, graph)
Find the module and import any SQify or STREAMify-decorated functions