summaryrefslogtreecommitdiff
path: root/checkers/variables.py
diff options
context:
space:
mode:
authorEmile Anclin <emile.anclin@logilab.fr>2009-03-10 10:35:10 +0100
committerEmile Anclin <emile.anclin@logilab.fr>2009-03-10 10:35:10 +0100
commit29a56b44e7bea55787cb2b323a1b4bca35bccd8f (patch)
tree8aca0f4312bc6fe997de27eaec65df166aaa27d5 /checkers/variables.py
parentcdcce626fdd19d9e47fb27b04f6d380c9ebc11d9 (diff)
downloadpylint-29a56b44e7bea55787cb2b323a1b4bca35bccd8f.tar.gz
we want the names, not AssName nodes : use new argnames method
Diffstat (limited to 'checkers/variables.py')
-rw-r--r--checkers/variables.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/checkers/variables.py b/checkers/variables.py
index 515c450..d97518c 100644
--- a/checkers/variables.py
+++ b/checkers/variables.py
@@ -230,7 +230,7 @@ builtins. Remember that you should avoid to define new builtins when possible.'
return
authorized_rgx = self.config.dummy_variables_rgx
overridden = marker = []
- args = node.args.args
+ argnames = node.argnames()
for name, stmts in not_consumed.iteritems():
# ignore some special names specified by user configuration
if authorized_rgx.match(name):
@@ -241,15 +241,15 @@ builtins. Remember that you should avoid to define new builtins when possible.'
if isinstance(stmt, astng.Global):
continue
# care about functions with unknown argument (builtins)
- if args and name in args:
+ if name in argnames:
if is_method:
# don't warn for the first argument of a (non static) method
- if node.type != 'staticmethod' and name == args[0]:
+ if node.type != 'staticmethod' and name == argnames[0]:
continue
# don't warn for argument of an overridden method
if overridden is marker:
overridden = overridden_method(klass, node.name)
- if overridden is not None and name in overridden.args.args:
+ if overridden is not None and name in overridden.argnames():
continue
# don't check callback arguments
if node.name.startswith('cb_') or \