Simplify and correct many numeric unions (#7906)

Unblocks PyCQA/flake8-pyi#222
This commit is contained in:
Alex Waygood
2022-05-21 15:25:00 +01:00
committed by GitHub
parent 7576805aee
commit 76a4bd796b
17 changed files with 30 additions and 26 deletions

View File

@@ -31,14 +31,14 @@ class Lock:
self, exc_type: type[BaseException] | None, exc_value: BaseException | None, traceback: TracebackType | None
) -> bool | None: ...
def acquire(
self, blocking: bool | None = ..., blocking_timeout: None | int | float = ..., token: str | bytes | None = ...
self, blocking: bool | None = ..., blocking_timeout: float | None = ..., token: str | bytes | None = ...
) -> bool: ...
def do_acquire(self, token: str | bytes) -> bool: ...
def locked(self) -> bool: ...
def owned(self) -> bool: ...
def release(self) -> None: ...
def do_release(self, expected_token: str | bytes) -> None: ...
def extend(self, additional_time: int | float, replace_ttl: bool = ...) -> bool: ...
def do_extend(self, additional_time: int | float, replace_ttl: bool) -> bool: ...
def extend(self, additional_time: float, replace_ttl: bool = ...) -> bool: ...
def do_extend(self, additional_time: float, replace_ttl: bool) -> bool: ...
def reacquire(self) -> bool: ...
def do_reacquire(self) -> bool: ...