summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorClaudiu Popa <pcmanticore@gmail.com>2015-12-08 13:41:06 +0200
committerClaudiu Popa <pcmanticore@gmail.com>2015-12-08 13:41:06 +0200
commit0e3da4d754adfe3ff727aa3183ea45ceed2b147b (patch)
tree857dd940ecbebc26d88646a2ac91033f0b691150
parentcb41aa237e4c637da2a9be4e44823d036e1e6430 (diff)
downloadpylint-0e3da4d754adfe3ff727aa3183ea45ceed2b147b.tar.gz
Change the attribute check for using hasattr instead of looking explicitly into __dict__.
-rw-r--r--pylint/pyreverse/utils.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/pylint/pyreverse/utils.py b/pylint/pyreverse/utils.py
index 9609ad0..90e973d 100644
--- a/pylint/pyreverse/utils.py
+++ b/pylint/pyreverse/utils.py
@@ -203,7 +203,7 @@ class LocalsVisitor(ASTWalker):
methods = self.get_callbacks(node)
if methods[0] is not None:
methods[0](node)
- if 'locals' in node.__dict__: # skip Instance and other proxy
+ if hasattr(node, 'locals'): # skip Instance and other proxy
for local_node in node.values():
self.visit(local_node)
if methods[1] is not None: