def astFunction(self, node): if hasattr(node, 'locals'): locs = self.locals self.locals = node.locals PyGen.astFunction(self, node) if hasattr(node, 'locals'): self.locals = locs
def generatePython(self, tree, options): pg = PyGen() pg.dispatch(tree) return pg.getCode()