Skip to content

Commit 3f121bf

Browse files
committed
Remove deprecated types
1 parent d87b4e6 commit 3f121bf

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

src/ast/tree.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
#!/usr/bin/python
22
# -*- coding: utf-8 -*-
33

4-
import collections
4+
import collections.abc
55

66
from typing import Iterable
77
from typing import List
@@ -39,7 +39,7 @@ def children(self):
3939

4040
@children.setter
4141
def children(self, value: Iterable):
42-
assert isinstance(value, collections.Iterable)
42+
assert isinstance(value, collections.abc.Iterable)
4343
while len(self.children):
4444
self.children.pop()
4545

@@ -129,7 +129,7 @@ def __len__(self):
129129

130130
def __add__(self, other):
131131
if not isinstance(other, ChildrenList):
132-
assert isinstance(other, collections.Container)
132+
assert isinstance(other, collections.abc.Container)
133133

134134
result = ChildrenList(self.owner)
135135
for x in self:

0 commit comments

Comments
 (0)