mirror of
https://github.com/davidhalter/typeshed.git
synced 2026-06-25 18:24:03 +08:00
Fix MutableMapping.update to require string keys (#14099)
This commit is contained in:
+7
-3
@@ -797,11 +797,15 @@ class MutableMapping(Mapping[_KT, _VT]):
|
||||
# -- weakref.WeakValueDictionary.__ior__
|
||||
# -- weakref.WeakKeyDictionary.__ior__
|
||||
@overload
|
||||
def update(self, m: SupportsKeysAndGetItem[_KT, _VT], /, **kwargs: _VT) -> None: ...
|
||||
def update(self, m: SupportsKeysAndGetItem[_KT, _VT], /) -> None: ...
|
||||
@overload
|
||||
def update(self, m: Iterable[tuple[_KT, _VT]], /, **kwargs: _VT) -> None: ...
|
||||
def update(self: Mapping[str, _VT], m: SupportsKeysAndGetItem[_KT, _VT], /, **kwargs: _VT) -> None: ...
|
||||
@overload
|
||||
def update(self, **kwargs: _VT) -> None: ...
|
||||
def update(self, m: Iterable[tuple[_KT, _VT]], /) -> None: ...
|
||||
@overload
|
||||
def update(self: Mapping[str, _VT], m: Iterable[tuple[_KT, _VT]], /, **kwargs: _VT) -> None: ...
|
||||
@overload
|
||||
def update(self: Mapping[str, _VT], **kwargs: _VT) -> None: ...
|
||||
|
||||
Text = str
|
||||
|
||||
|
||||
Reference in New Issue
Block a user