Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 0 additions & 14 deletions stdlib/2/collections.pyi
Original file line number Diff line number Diff line change
Expand Up @@ -92,17 +92,3 @@ class defaultdict(Dict[_KT, _VT], Generic[_KT, _VT]):
def __init__(self, default_factory: Callable[[], _VT],
iterable: Iterable[Tuple[_KT, _VT]]) -> None: ...
def __missing__(self, key: _KT) -> _VT: ...

class ChainMap(Dict[_KT, _VT], Generic[_KT, _VT]):
@overload
def __init__(self) -> None: ...
@overload
def __init__(self, *maps: Mapping[_KT, _VT]) -> None: ...

@property
def maps(self) -> List[Mapping[_KT, _VT]]: ...

def new_child(self, m: Mapping[_KT, _VT] = ...) -> ChainMap[_KT, _VT]: ...

@property
def parents(self) -> ChainMap[_KT, _VT]: ...
21 changes: 11 additions & 10 deletions stdlib/3/collections/__init__.pyi
Original file line number Diff line number Diff line change
Expand Up @@ -166,16 +166,17 @@ class defaultdict(Dict[_KT, _VT], Generic[_KT, _VT]):
def __missing__(self, key: _KT) -> _VT: ...
# TODO __reversed__

class ChainMap(Dict[_KT, _VT], Generic[_KT, _VT]):
@overload
def __init__(self) -> None: ...
@overload
def __init__(self, *maps: Mapping[_KT, _VT]) -> None: ...
if sys.version_info >= (3, 3):
class ChainMap(MutableMapping[_KT, _VT], Generic[_KT, _VT]):
@overload
def __init__(self) -> None: ...
@overload
def __init__(self, *maps: Mapping[_KT, _VT]) -> None: ...

@property
def maps(self) -> List[Mapping[_KT, _VT]]: ...
@property
def maps(self) -> List[Mapping[_KT, _VT]]: ...

def new_child(self, m: Mapping[_KT, _VT] = ...) -> ChainMap[_KT, _VT]: ...
def new_child(self, m: Mapping[_KT, _VT] = ...) -> ChainMap[_KT, _VT]: ...

@property
def parents(self) -> ChainMap[_KT, _VT]: ...
@property
def parents(self) -> ChainMap[_KT, _VT]: ...