mirror of
https://github.com/davidhalter/typeshed.git
synced 2025-12-07 20:54:28 +08:00
Add __class_getitem__ methods new in py313 (#12029)
This commit is contained in:
@@ -151,8 +151,6 @@ mimetypes.MimeTypes.guess_file_type
|
||||
mimetypes.__all__
|
||||
mimetypes.guess_file_type
|
||||
mmap.mmap.seekable
|
||||
multiprocessing.managers.DictProxy.__class_getitem__
|
||||
multiprocessing.managers.ListProxy.__class_getitem__
|
||||
multiprocessing.shared_memory.SharedMemory.__init__
|
||||
pathlib.Path.__enter__
|
||||
pathlib.Path.__exit__
|
||||
@@ -232,8 +230,6 @@ turtle.RawTurtle.settiltangle
|
||||
turtle.__all__
|
||||
turtle.settiltangle
|
||||
types.CodeType.__replace__
|
||||
types.CoroutineType.__class_getitem__
|
||||
types.GeneratorType.__class_getitem__
|
||||
types.MappingProxyType.get
|
||||
types.SimpleNamespace.__replace__
|
||||
typing.ForwardRef._evaluate
|
||||
|
||||
@@ -83,6 +83,8 @@ class DictProxy(BaseProxy, MutableMapping[_KT, _VT]):
|
||||
def keys(self) -> list[_KT]: ... # type: ignore[override]
|
||||
def items(self) -> list[tuple[_KT, _VT]]: ... # type: ignore[override]
|
||||
def values(self) -> list[_VT]: ... # type: ignore[override]
|
||||
if sys.version_info >= (3, 13):
|
||||
def __class_getitem__(cls, args: Any, /) -> Any: ...
|
||||
|
||||
class BaseListProxy(BaseProxy, MutableSequence[_T]):
|
||||
__builtins__: ClassVar[dict[str, Any]]
|
||||
@@ -117,6 +119,8 @@ class BaseListProxy(BaseProxy, MutableSequence[_T]):
|
||||
class ListProxy(BaseListProxy[_T]):
|
||||
def __iadd__(self, value: Iterable[_T], /) -> Self: ... # type: ignore[override]
|
||||
def __imul__(self, value: SupportsIndex, /) -> Self: ... # type: ignore[override]
|
||||
if sys.version_info >= (3, 13):
|
||||
def __class_getitem__(cls, args: Any, /) -> Any: ...
|
||||
|
||||
# Returned by BaseManager.get_server()
|
||||
class Server:
|
||||
|
||||
@@ -358,6 +358,8 @@ class GeneratorType(Generator[_YieldT_co, _SendT_contra, _ReturnT_co]):
|
||||
) -> _YieldT_co: ...
|
||||
@overload
|
||||
def throw(self, typ: BaseException, val: None = None, tb: TracebackType | None = ..., /) -> _YieldT_co: ...
|
||||
if sys.version_info >= (3, 13):
|
||||
def __class_getitem__(cls, item: Any, /) -> Any: ...
|
||||
|
||||
@final
|
||||
class AsyncGeneratorType(AsyncGenerator[_YieldT_co, _SendT_contra]):
|
||||
@@ -401,6 +403,8 @@ class CoroutineType(Coroutine[_YieldT_co, _SendT_contra, _ReturnT_co]):
|
||||
) -> _YieldT_co: ...
|
||||
@overload
|
||||
def throw(self, typ: BaseException, val: None = None, tb: TracebackType | None = ..., /) -> _YieldT_co: ...
|
||||
if sys.version_info >= (3, 13):
|
||||
def __class_getitem__(cls, item: Any, /) -> Any: ...
|
||||
|
||||
@final
|
||||
class MethodType:
|
||||
|
||||
Reference in New Issue
Block a user