diff options
| author | Sylvain Thénault <sylvain.thenault@logilab.fr> | 2013-02-25 12:00:10 +0100 |
|---|---|---|
| committer | Sylvain Thénault <sylvain.thenault@logilab.fr> | 2013-02-25 12:00:10 +0100 |
| commit | 37b07b305fb190df034b2810d47e194938fc26ce (patch) | |
| tree | 47261a9f1eae0512b4b45c4d4a9ee1553c23e914 /checkers/utils.py | |
| parent | 2e57298846aeb72b589329f63af434bf9d74f398 (diff) | |
| download | pylint-git-37b07b305fb190df034b2810d47e194938fc26ce.tar.gz | |
use .fromlineno instead of .lineno (which is not reliable)
Diffstat (limited to 'checkers/utils.py')
| -rw-r--r-- | checkers/utils.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/checkers/utils.py b/checkers/utils.py index 2115b5149..aa4563ee4 100644 --- a/checkers/utils.py +++ b/checkers/utils.py @@ -1,6 +1,6 @@ # pylint: disable=W0611 # -# Copyright (c) 2003-2010 LOGILAB S.A. (Paris, FRANCE). +# Copyright (c) 2003-2013 LOGILAB S.A. (Paris, FRANCE). # http://www.logilab.fr/ -- mailto:contact@logilab.fr # # This program is free software; you can redistribute it and/or modify it under @@ -65,7 +65,7 @@ def clobber_in_except(node): if (stmts and not isinstance(stmts[0].ass_type(), (astng.Assign, astng.AugAssign, astng.ExceptHandler))): - return (True, (name, 'outer scope (line %s)' % (stmts[0].lineno,))) + return (True, (name, 'outer scope (line %s)' % (stmts[0].fromlineno,))) return (False, None) |
