Switch to PEP-604 syntax in python2 stubs (#5915)

Signed-off-by: oleg.hoefling <oleg.hoefling@gmail.com>
This commit is contained in:
Oleg Höfling
2021-08-14 11:12:30 +02:00
committed by GitHub
parent 431c4f7fc1
commit ff63953188
235 changed files with 2473 additions and 2768 deletions

View File

@@ -1,15 +1,15 @@
from typing import AnyStr, Callable, Dict, Generic, Iterable, List, Optional, Sequence, Text, Tuple, Union
from typing import AnyStr, Callable, Dict, Generic, Iterable, List, Sequence, Text, Tuple
DEFAULT_IGNORES: List[str]
def cmp(f1: Union[bytes, Text], f2: Union[bytes, Text], shallow: Union[int, bool] = ...) -> bool: ...
def cmp(f1: bytes | Text, f2: bytes | Text, shallow: int | bool = ...) -> bool: ...
def cmpfiles(
a: AnyStr, b: AnyStr, common: Iterable[AnyStr], shallow: Union[int, bool] = ...
a: AnyStr, b: AnyStr, common: Iterable[AnyStr], shallow: int | bool = ...
) -> Tuple[List[AnyStr], List[AnyStr], List[AnyStr]]: ...
class dircmp(Generic[AnyStr]):
def __init__(
self, a: AnyStr, b: AnyStr, ignore: Optional[Sequence[AnyStr]] = ..., hide: Optional[Sequence[AnyStr]] = ...
self, a: AnyStr, b: AnyStr, ignore: Sequence[AnyStr] | None = ..., hide: Sequence[AnyStr] | None = ...
) -> None: ...
left: AnyStr
right: AnyStr