mirror of
https://github.com/davidhalter/typeshed.git
synced 2025-12-08 04:54:47 +08:00
Big diff: Use new "|" union syntax (#5872)
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
from typing import Any, Iterable, Mapping, Optional, Sequence, Tuple, Union
|
||||
from typing import Any, Iterable, Mapping, Sequence, Tuple
|
||||
|
||||
ascii_letters: str
|
||||
ascii_lowercase: str
|
||||
@@ -10,7 +10,7 @@ punctuation: str
|
||||
printable: str
|
||||
whitespace: str
|
||||
|
||||
def capwords(s: str, sep: Optional[str] = ...) -> str: ...
|
||||
def capwords(s: str, sep: str | None = ...) -> str: ...
|
||||
|
||||
class Template:
|
||||
template: str
|
||||
@@ -22,9 +22,9 @@ class Template:
|
||||
class Formatter:
|
||||
def format(self, __format_string: str, *args: Any, **kwargs: Any) -> str: ...
|
||||
def vformat(self, format_string: str, args: Sequence[Any], kwargs: Mapping[str, Any]) -> str: ...
|
||||
def parse(self, format_string: str) -> Iterable[Tuple[str, Optional[str], Optional[str], Optional[str]]]: ...
|
||||
def parse(self, format_string: str) -> Iterable[Tuple[str, str | None, str | None, str | None]]: ...
|
||||
def get_field(self, field_name: str, args: Sequence[Any], kwargs: Mapping[str, Any]) -> Any: ...
|
||||
def get_value(self, key: Union[int, str], args: Sequence[Any], kwargs: Mapping[str, Any]) -> Any: ...
|
||||
def check_unused_args(self, used_args: Sequence[Union[int, str]], args: Sequence[Any], kwargs: Mapping[str, Any]) -> None: ...
|
||||
def get_value(self, key: int | str, args: Sequence[Any], kwargs: Mapping[str, Any]) -> Any: ...
|
||||
def check_unused_args(self, used_args: Sequence[int | str], args: Sequence[Any], kwargs: Mapping[str, Any]) -> None: ...
|
||||
def format_field(self, value: Any, format_spec: str) -> Any: ...
|
||||
def convert_field(self, value: Any, conversion: str) -> Any: ...
|
||||
|
||||
Reference in New Issue
Block a user