Issue #25670: Remove duplicate getattr() from ast.NodeTransformer

This commit is contained in:
Victor Stinner 2015-11-20 08:49:58 +01:00
parent 97cabb9fa5
commit 6fbd7741db

View file

@ -293,7 +293,6 @@ class NodeTransformer(NodeVisitor):
def generic_visit(self, node):
for field, old_value in iter_fields(node):
old_value = getattr(node, field, None)
if isinstance(old_value, list):
new_values = []
for value in old_value: