diff options
Diffstat (limited to 'pylint/checkers/variables.py')
-rw-r--r-- | pylint/checkers/variables.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/pylint/checkers/variables.py b/pylint/checkers/variables.py index f0f0fa0..cde66eb 100644 --- a/pylint/checkers/variables.py +++ b/pylint/checkers/variables.py @@ -729,7 +729,7 @@ builtins. Remember that you should avoid to define new builtins when possible.' assign = astmts[0].assign_type() if (isinstance(assign, (astroid.For, astroid.Comprehension, astroid.GeneratorExp)) - and not assign.statement() is node.statement()): + and assign.statement() is not node.statement()): self.add_message('undefined-loop-variable', args=name, node=node) @check_messages('redefine-in-handler') |