]> git.proxmox.com Git - mirror_edk2.git/blobdiff - AppPkg/Applications/Python/Python-2.7.2/Lib/lib2to3/fixes/fix_exec.py
edk2: Remove AppPkg, StdLib, StdLibPrivateInternalFiles
[mirror_edk2.git] / AppPkg / Applications / Python / Python-2.7.2 / Lib / lib2to3 / fixes / fix_exec.py
diff --git a/AppPkg/Applications/Python/Python-2.7.2/Lib/lib2to3/fixes/fix_exec.py b/AppPkg/Applications/Python/Python-2.7.2/Lib/lib2to3/fixes/fix_exec.py
deleted file mode 100644 (file)
index 163683b..0000000
+++ /dev/null
@@ -1,40 +0,0 @@
-# Copyright 2006 Google, Inc. All Rights Reserved.\r
-# Licensed to PSF under a Contributor Agreement.\r
-\r
-"""Fixer for exec.\r
-\r
-This converts usages of the exec statement into calls to a built-in\r
-exec() function.\r
-\r
-exec code in ns1, ns2 -> exec(code, ns1, ns2)\r
-"""\r
-\r
-# Local imports\r
-from .. import pytree\r
-from .. import fixer_base\r
-from ..fixer_util import Comma, Name, Call\r
-\r
-\r
-class FixExec(fixer_base.BaseFix):\r
-    BM_compatible = True\r
-\r
-    PATTERN = """\r
-    exec_stmt< 'exec' a=any 'in' b=any [',' c=any] >\r
-    |\r
-    exec_stmt< 'exec' (not atom<'(' [any] ')'>) a=any >\r
-    """\r
-\r
-    def transform(self, node, results):\r
-        assert results\r
-        syms = self.syms\r
-        a = results["a"]\r
-        b = results.get("b")\r
-        c = results.get("c")\r
-        args = [a.clone()]\r
-        args[0].prefix = ""\r
-        if b is not None:\r
-            args.extend([Comma(), b.clone()])\r
-        if c is not None:\r
-            args.extend([Comma(), c.clone()])\r
-\r
-        return Call(Name(u"exec"), args, prefix=node.prefix)\r