massive update, probably broken
[dotfiles/.git] / .config / coc / extensions / coc-python-data / languageServer.0.5.59 / Typeshed / stdlib / 2and3 / dis.pyi
diff --git a/.config/coc/extensions/coc-python-data/languageServer.0.5.59/Typeshed/stdlib/2and3/dis.pyi b/.config/coc/extensions/coc-python-data/languageServer.0.5.59/Typeshed/stdlib/2and3/dis.pyi
new file mode 100644 (file)
index 0000000..a59aaa6
--- /dev/null
@@ -0,0 +1,75 @@
+from typing import List, Union, Iterator, Tuple, Optional, Any, IO, NamedTuple, Dict\r
+\r
+import sys\r
+import types\r
+\r
+from opcode import (hasconst as hasconst, hasname as hasname, hasjrel as hasjrel,\r
+                    hasjabs as hasjabs, haslocal as haslocal, hascompare as hascompare,\r
+                    hasfree as hasfree, cmp_op as cmp_op, opname as opname, opmap as opmap,\r
+                    HAVE_ARGUMENT as HAVE_ARGUMENT, EXTENDED_ARG as EXTENDED_ARG)\r
+\r
+if sys.version_info >= (3, 4):\r
+    from opcode import stack_effect as stack_effect\r
+\r
+if sys.version_info >= (3, 6):\r
+    from opcode import hasnargs as hasnargs\r
+\r
+_have_code = Union[types.MethodType, types.FunctionType, types.CodeType, type]\r
+_have_code_or_string = Union[_have_code, str, bytes]\r
+\r
+\r
+if sys.version_info >= (3, 4):\r
+    Instruction = NamedTuple(\r
+        "Instruction",\r
+        [\r
+            ('opname', str),\r
+            ('opcode', int),\r
+            ('arg', Optional[int]),\r
+            ('argval', Any),\r
+            ('argrepr', str),\r
+            ('offset', int),\r
+            ('starts_line', Optional[int]),\r
+            ('is_jump_target', bool)\r
+        ]\r
+    )\r
+\r
+    class Bytecode:\r
+        codeobj = ...  # type: types.CodeType\r
+        first_line = ...  # type: int\r
+        def __init__(self, x: _have_code_or_string, *, first_line: Optional[int] = ...,\r
+                     current_offset: Optional[int] = ...) -> None: ...\r
+        def __iter__(self) -> Iterator[Instruction]: ...\r
+        def __repr__(self) -> str: ...\r
+        def info(self) -> str: ...\r
+        def dis(self) -> str: ...\r
+\r
+        @classmethod\r
+        def from_traceback(cls, tb: types.TracebackType) -> Bytecode: ...\r
+\r
+\r
+COMPILER_FLAG_NAMES = ...  # type:  Dict[int, str]\r
+\r
+\r
+def findlabels(code: _have_code) -> List[int]: ...\r
+def findlinestarts(code: _have_code) -> Iterator[Tuple[int, int]]: ...\r
+\r
+if sys.version_info >= (3, 0):\r
+    def pretty_flags(flags: int) -> str: ...\r
+    def code_info(x: _have_code_or_string) -> str: ...\r
+\r
+if sys.version_info >= (3, 4):\r
+    def dis(x: _have_code_or_string = ..., *, file: Optional[IO[str]] = ...) -> None: ...\r
+    def distb(tb: Optional[types.TracebackType] = ..., *, file: Optional[IO[str]] = ...) -> None: ...\r
+    def disassemble(co: _have_code, lasti: int = ..., *, file: Optional[IO[str]] = ...) -> None: ...\r
+    def disco(co: _have_code, lasti: int = ..., *, file: Optional[IO[str]] = ...) -> None: ...\r
+    def show_code(co: _have_code, *, file: Optional[IO[str]] = ...) -> None: ...\r
+\r
+    def get_instructions(x: _have_code, *, first_line: Optional[int] = ...) -> Iterator[Instruction]: ...\r
+else:\r
+    def dis(x: _have_code_or_string = ...) -> None: ...\r
+    def distb(tb: types.TracebackType = ...) -> None: ...\r
+    def disassemble(co: _have_code, lasti: int = ...) -> None: ...\r
+    def disco(co: _have_code, lasti: int = ...) -> None: ...\r
+\r
+    if sys.version_info >= (3, 0):\r
+        def show_code(co: _have_code) -> None: ...\r