File: plugin_attrs.pyi

package info (click to toggle)
mypy 1.19.1-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 22,412 kB
  • sloc: python: 114,754; ansic: 13,343; cpp: 11,380; makefile: 257; sh: 28
file content (39 lines) | stat: -rw-r--r-- 1,191 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
# Builtins stub used to support attrs plugin tests.
from typing import Union, overload, Generic, Sequence, TypeVar, Type, Iterable, Iterator

class object:
    def __init__(self) -> None: pass
    def __eq__(self, o: object) -> bool: pass
    def __ne__(self, o: object) -> bool: pass
    def __hash__(self) -> int: ...

class type: pass
class bytes: pass
class function: pass
class float: pass
class int:
    @overload
    def __init__(self, x: Union[str, bytes, int] = ...) -> None: ...
    @overload
    def __init__(self, x: Union[str, bytes], base: int) -> None: ...
class bool(int): pass
class complex:
    @overload
    def __init__(self, real: float = ..., im: float = ...) -> None: ...
    @overload
    def __init__(self, real: str = ...) -> None: ...

class str: pass
class ellipsis: pass
class list: pass
class dict: pass

T = TypeVar("T")
Tco = TypeVar('Tco', covariant=True)
class tuple(Sequence[Tco], Generic[Tco]):
    def __new__(cls: Type[T], iterable: Iterable[Tco] = ...) -> T: ...
    def __iter__(self) -> Iterator[Tco]: pass
    def __contains__(self, item: object) -> bool: pass
    def __getitem__(self, x: int) -> Tco: pass

property = object()  # Dummy definition