mirror of
https://github.com/davidhalter/typeshed.git
synced 2025-12-20 10:51:15 +08:00
Use PEP 570 syntax in stdlib (#11250)
This commit is contained in:
@@ -10,14 +10,14 @@ LC_NUMERIC: int
|
||||
LC_ALL: int
|
||||
CHAR_MAX: int
|
||||
|
||||
def setlocale(__category: int, __locale: str | None = None) -> str: ...
|
||||
def setlocale(category: int, locale: str | None = None, /) -> str: ...
|
||||
def localeconv() -> Mapping[str, int | str | list[int]]: ...
|
||||
|
||||
if sys.version_info >= (3, 11):
|
||||
def getencoding() -> str: ...
|
||||
|
||||
def strcoll(__os1: str, __os2: str) -> int: ...
|
||||
def strxfrm(__string: str) -> str: ...
|
||||
def strcoll(os1: str, os2: str, /) -> int: ...
|
||||
def strxfrm(string: str, /) -> str: ...
|
||||
|
||||
# native gettext functions
|
||||
# https://docs.python.org/3/library/locale.html#access-to-message-catalogs
|
||||
@@ -87,14 +87,14 @@ if sys.platform != "win32":
|
||||
CRNCYSTR: int
|
||||
ALT_DIGITS: int
|
||||
|
||||
def nl_langinfo(__key: int) -> str: ...
|
||||
def nl_langinfo(key: int, /) -> str: ...
|
||||
|
||||
# This is dependent on `libintl.h` which is a part of `gettext`
|
||||
# system dependency. These functions might be missing.
|
||||
# But, we always say that they are present.
|
||||
def gettext(__msg: str) -> str: ...
|
||||
def dgettext(__domain: str | None, __msg: str) -> str: ...
|
||||
def dcgettext(__domain: str | None, __msg: str, __category: int) -> str: ...
|
||||
def textdomain(__domain: str | None) -> str: ...
|
||||
def bindtextdomain(__domain: str, __dir: StrPath | None) -> str: ...
|
||||
def bind_textdomain_codeset(__domain: str, __codeset: str | None) -> str | None: ...
|
||||
def gettext(msg: str, /) -> str: ...
|
||||
def dgettext(domain: str | None, msg: str, /) -> str: ...
|
||||
def dcgettext(domain: str | None, msg: str, category: int, /) -> str: ...
|
||||
def textdomain(domain: str | None, /) -> str: ...
|
||||
def bindtextdomain(domain: str, dir: StrPath | None, /) -> str: ...
|
||||
def bind_textdomain_codeset(domain: str, codeset: str | None, /) -> str | None: ...
|
||||
|
||||
Reference in New Issue
Block a user