mirror of
https://github.com/davidhalter/typeshed.git
synced 2025-12-10 05:51:52 +08:00
Use PEP 585 syntax in Python 2, protobuf & _ast stubs, where possible (#6949)
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
# workaround for mypy#2010
|
||||
from __builtin__ import str as _str
|
||||
from decimal import Decimal
|
||||
from typing import Any, Callable, Dict, Iterable, List, Mapping, Sequence, Tuple
|
||||
from typing import Any, Callable, Iterable, Mapping, Sequence
|
||||
|
||||
CODESET: int
|
||||
D_T_FMT: int
|
||||
@@ -75,9 +75,9 @@ CHAR_MAX: int
|
||||
class Error(Exception): ...
|
||||
|
||||
def setlocale(category: int, locale: _str | Iterable[_str] | None = ...) -> _str: ...
|
||||
def localeconv() -> Mapping[_str, int | _str | List[int]]: ...
|
||||
def localeconv() -> Mapping[_str, int | _str | list[int]]: ...
|
||||
def nl_langinfo(__key: int) -> _str: ...
|
||||
def getdefaultlocale(envvars: Tuple[_str, ...] = ...) -> Tuple[_str | None, _str | None]: ...
|
||||
def getdefaultlocale(envvars: tuple[_str, ...] = ...) -> tuple[_str | None, _str | None]: ...
|
||||
def getlocale(category: int = ...) -> Sequence[_str]: ...
|
||||
def getpreferredencoding(do_setlocale: bool = ...) -> _str: ...
|
||||
def normalize(localename: _str) -> _str: ...
|
||||
@@ -91,6 +91,6 @@ def atof(string: _str, func: Callable[[_str], float] = ...) -> float: ...
|
||||
def atoi(string: _str) -> int: ...
|
||||
def str(val: float) -> _str: ...
|
||||
|
||||
locale_alias: Dict[_str, _str] # undocumented
|
||||
locale_encoding_alias: Dict[_str, _str] # undocumented
|
||||
windows_locale: Dict[int, _str] # undocumented
|
||||
locale_alias: dict[_str, _str] # undocumented
|
||||
locale_encoding_alias: dict[_str, _str] # undocumented
|
||||
windows_locale: dict[int, _str] # undocumented
|
||||
|
||||
Reference in New Issue
Block a user