diff options
author | monster <[email protected]> | 2022-07-07 14:41:37 +0300 |
---|---|---|
committer | monster <[email protected]> | 2022-07-07 14:41:37 +0300 |
commit | 06e5c21a835c0e923506c4ff27929f34e00761c2 (patch) | |
tree | 75efcbc6854ef9bd476eb8bf00cc5c900da436a2 /contrib/tools/cython/Cython/Compiler/CodeGeneration.py | |
parent | 03f024c4412e3aa613bb543cf1660176320ba8f4 (diff) |
fix ya.make
Diffstat (limited to 'contrib/tools/cython/Cython/Compiler/CodeGeneration.py')
-rw-r--r-- | contrib/tools/cython/Cython/Compiler/CodeGeneration.py | 35 |
1 files changed, 0 insertions, 35 deletions
diff --git a/contrib/tools/cython/Cython/Compiler/CodeGeneration.py b/contrib/tools/cython/Cython/Compiler/CodeGeneration.py deleted file mode 100644 index e64049c7f5d..00000000000 --- a/contrib/tools/cython/Cython/Compiler/CodeGeneration.py +++ /dev/null @@ -1,35 +0,0 @@ -from __future__ import absolute_import - -from .Visitor import VisitorTransform -from .Nodes import StatListNode - - -class ExtractPxdCode(VisitorTransform): - """ - Finds nodes in a pxd file that should generate code, and - returns them in a StatListNode. - - The result is a tuple (StatListNode, ModuleScope), i.e. - everything that is needed from the pxd after it is processed. - - A purer approach would be to separately compile the pxd code, - but the result would have to be slightly more sophisticated - than pure strings (functions + wanted interned strings + - wanted utility code + wanted cached objects) so for now this - approach is taken. - """ - - def __call__(self, root): - self.funcs = [] - self.visitchildren(root) - return (StatListNode(root.pos, stats=self.funcs), root.scope) - - def visit_FuncDefNode(self, node): - self.funcs.append(node) - # Do not visit children, nested funcdefnodes will - # also be moved by this action... - return node - - def visit_Node(self, node): - self.visitchildren(node) - return node |