Enable --disallow-any-generics for stubs (#3288)

This commit is contained in:
Sebastian Rittau
2019-10-01 14:31:34 +02:00
committed by Jelle Zijlstra
parent 23b353303b
commit c32e1e2280
77 changed files with 386 additions and 329 deletions

View File

@@ -40,6 +40,7 @@ else:
_CMD = Union[_TXT, Sequence[_PATH]]
_ENV = Union[Mapping[bytes, _TXT], Mapping[Text, _TXT]]
_S = TypeVar('_S')
_T = TypeVar('_T')
class CompletedProcess(Generic[_T]):
@@ -1169,7 +1170,7 @@ class Popen(Generic[AnyStr]):
def send_signal(self, signal: int) -> None: ...
def terminate(self) -> None: ...
def kill(self) -> None: ...
def __enter__(self) -> Popen: ...
def __enter__(self: _S) -> _S: ...
def __exit__(self, type: Optional[Type[BaseException]], value: Optional[BaseException], traceback: Optional[TracebackType]) -> None: ...
# The result really is always a str.