mirror of
https://github.com/davidhalter/typeshed.git
synced 2025-12-10 05:51:52 +08:00
Use the FileDescriptorOrPath alias consistently in the stdlib (#9513)
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
import sys
|
||||
from _typeshed import StrOrBytesPath
|
||||
from _typeshed import FileDescriptorOrPath
|
||||
from collections.abc import Callable, Generator, Iterable, Sequence
|
||||
from re import Pattern
|
||||
from token import *
|
||||
@@ -125,7 +125,7 @@ def untokenize(iterable: Iterable[_Token]) -> Any: ...
|
||||
def detect_encoding(readline: Callable[[], bytes | bytearray]) -> tuple[str, Sequence[bytes]]: ...
|
||||
def tokenize(readline: Callable[[], bytes | bytearray]) -> Generator[TokenInfo, None, None]: ...
|
||||
def generate_tokens(readline: Callable[[], str]) -> Generator[TokenInfo, None, None]: ... # undocumented
|
||||
def open(filename: StrOrBytesPath | int) -> TextIO: ...
|
||||
def open(filename: FileDescriptorOrPath) -> TextIO: ...
|
||||
def group(*choices: str) -> str: ... # undocumented
|
||||
def any(*choices: str) -> str: ... # undocumented
|
||||
def maybe(*choices: str) -> str: ... # undocumented
|
||||
|
||||
Reference in New Issue
Block a user