diff --git a/stdlib/2/__builtin__.pyi b/stdlib/2/__builtin__.pyi index 541122b27..33b25f56d 100644 --- a/stdlib/2/__builtin__.pyi +++ b/stdlib/2/__builtin__.pyi @@ -574,9 +574,11 @@ class dict(MutableMapping[_KT, _VT], Generic[_KT, _VT]): def popitem(self) -> Tuple[_KT, _VT]: ... def setdefault(self, k: _KT, default: _VT = ...) -> _VT: ... @overload - def update(self, m: Mapping[_KT, _VT], **kwargs: _VT) -> None: ... + def update(self, __m: Mapping[_KT, _VT], **kwargs: _VT) -> None: ... @overload - def update(self, m: Iterable[Tuple[_KT, _VT]], **kwargs: _VT) -> None: ... + def update(self, __m: Iterable[Tuple[_KT, _VT]], **kwargs: _VT) -> None: ... + @overload + def update(self, **kwargs: _VT) -> None: ... def iterkeys(self) -> Iterator[_KT]: ... def itervalues(self) -> Iterator[_VT]: ... def iteritems(self) -> Iterator[Tuple[_KT, _VT]]: ... diff --git a/stdlib/2/collections.pyi b/stdlib/2/collections.pyi index 4a56ea5a4..1fab27443 100644 --- a/stdlib/2/collections.pyi +++ b/stdlib/2/collections.pyi @@ -78,9 +78,11 @@ class Counter(Dict[_T, int], Generic[_T]): # Dict.update. Not sure if we should use '# type: ignore' instead # and omit the type from the union. @overload - def update(self, m: Mapping[_T, int], **kwargs: int) -> None: ... + def update(self, __m: Mapping[_T, int], **kwargs: int) -> None: ... @overload - def update(self, m: Union[Iterable[_T], Iterable[Tuple[_T, int]]], **kwargs: int) -> None: ... + def update(self, __m: Union[Iterable[_T], Iterable[Tuple[_T, int]]], **kwargs: int) -> None: ... + @overload + def update(self, **kwargs: int) -> None: ... def __add__(self, other: Counter[_T]) -> Counter[_T]: ... def __sub__(self, other: Counter[_T]) -> Counter[_T]: ... diff --git a/stdlib/2/typing.pyi b/stdlib/2/typing.pyi index 73497f9aa..0fef6d4a1 100644 --- a/stdlib/2/typing.pyi +++ b/stdlib/2/typing.pyi @@ -238,9 +238,11 @@ class MutableMapping(Mapping[_KT, _VT], Generic[_KT, _VT]): def popitem(self) -> Tuple[_KT, _VT]: ... def setdefault(self, k: _KT, default: _VT = ...) -> _VT: ... @overload - def update(self, m: Mapping[_KT, _VT], **kwargs: _VT) -> None: ... + def update(self, __m: Mapping[_KT, _VT], **kwargs: _VT) -> None: ... @overload - def update(self, m: Iterable[Tuple[_KT, _VT]], **kwargs: _VT) -> None: ... + def update(self, __m: Iterable[Tuple[_KT, _VT]], **kwargs: _VT) -> None: ... + @overload + def update(self, **kwargs: _VT) -> None: ... Text = unicode diff --git a/stdlib/3/builtins.pyi b/stdlib/3/builtins.pyi index f2a3b1b92..8ccd0363c 100644 --- a/stdlib/3/builtins.pyi +++ b/stdlib/3/builtins.pyi @@ -635,9 +635,11 @@ class dict(MutableMapping[_KT, _VT], Generic[_KT, _VT]): def popitem(self) -> Tuple[_KT, _VT]: ... def setdefault(self, k: _KT, default: _VT = None) -> _VT: ... @overload - def update(self, m: Mapping[_KT, _VT], **kwargs: _VT) -> None: ... + def update(self, __m: Mapping[_KT, _VT], **kwargs: _VT) -> None: ... @overload - def update(self, m: Iterable[Tuple[_KT, _VT]], **kwargs: _VT) -> None: ... + def update(self, __m: Iterable[Tuple[_KT, _VT]], **kwargs: _VT) -> None: ... + @overload + def update(self, **kwargs: _VT) -> None: ... def keys(self) -> KeysView[_KT]: ... def values(self) -> ValuesView[_VT]: ... def items(self) -> ItemsView[_KT, _VT]: ... diff --git a/stdlib/3/collections/__init__.pyi b/stdlib/3/collections/__init__.pyi index e31bbf7b6..e10d86183 100644 --- a/stdlib/3/collections/__init__.pyi +++ b/stdlib/3/collections/__init__.pyi @@ -138,9 +138,11 @@ class Counter(Dict[_T, int], Generic[_T]): # Dict.update. Not sure if we should use '# type: ignore' instead # and omit the type from the union. @overload - def update(self, m: Mapping[_T, int], **kwargs: int) -> None: ... + def update(self, __m: Mapping[_T, int], **kwargs: int) -> None: ... @overload - def update(self, m: Union[Iterable[_T], Iterable[Tuple[_T, int]]], **kwargs: int) -> None: ... + def update(self, __m: Union[Iterable[_T], Iterable[Tuple[_T, int]]], **kwargs: int) -> None: ... + @overload + def update(self, **kwargs: int) -> None: ... def __add__(self, other: Counter[_T]) -> Counter[_T]: ... def __sub__(self, other: Counter[_T]) -> Counter[_T]: ... diff --git a/stdlib/3/typing.pyi b/stdlib/3/typing.pyi index cb2a2c92a..a7899a4a2 100644 --- a/stdlib/3/typing.pyi +++ b/stdlib/3/typing.pyi @@ -327,9 +327,11 @@ class MutableMapping(Mapping[_KT, _VT], Generic[_KT, _VT]): # known to be a Mapping with unknown type parameters, which is closer # to the behavior we want. See mypy issue #1430. @overload - def update(self, m: Mapping[_KT, _VT], **kwargs: _VT) -> None: ... + def update(self, __m: Mapping[_KT, _VT], **kwargs: _VT) -> None: ... @overload - def update(self, m: Iterable[Tuple[_KT, _VT]], **kwargs: _VT) -> None: ... + def update(self, __m: Iterable[Tuple[_KT, _VT]], **kwargs: _VT) -> None: ... + @overload + def update(self, **kwargs: _VT) -> None: ... Text = str