mirror of
https://github.com/davidhalter/typeshed.git
synced 2025-12-08 13:04:46 +08:00
stdlib: Add several missing __(deep)copy__ methods (#7242)
This commit is contained in:
@@ -46,6 +46,8 @@ class WeakValueDictionary(MutableMapping[_KT, _VT]):
|
||||
def __contains__(self, o: object) -> bool: ...
|
||||
def __iter__(self) -> Iterator[_KT]: ...
|
||||
def copy(self) -> WeakValueDictionary[_KT, _VT]: ...
|
||||
__copy__ = copy
|
||||
def __deepcopy__(self: Self, memo: Any) -> Self: ...
|
||||
# These are incompatible with Mapping
|
||||
def keys(self) -> Iterator[_KT]: ... # type: ignore[override]
|
||||
def values(self) -> Iterator[_VT]: ... # type: ignore[override]
|
||||
@@ -84,6 +86,8 @@ class WeakKeyDictionary(MutableMapping[_KT, _VT]):
|
||||
def __contains__(self, o: object) -> bool: ...
|
||||
def __iter__(self) -> Iterator[_KT]: ...
|
||||
def copy(self) -> WeakKeyDictionary[_KT, _VT]: ...
|
||||
__copy__ = copy
|
||||
def __deepcopy__(self: Self, memo: Any) -> Self: ...
|
||||
# These are incompatible with Mapping
|
||||
def keys(self) -> Iterator[_KT]: ... # type: ignore[override]
|
||||
def values(self) -> Iterator[_VT]: ... # type: ignore[override]
|
||||
|
||||
Reference in New Issue
Block a user