Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(16)

Unified Diff: third_party/pylint/pyreverse/diadefslib.py

Issue 753543006: pylint: upgrade to 1.4.0 (Closed) Base URL: https://chromium.googlesource.com/chromium/tools/depot_tools.git@master
Patch Set: Created 6 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « third_party/pylint/lint.py ('k') | third_party/pylint/pyreverse/diagrams.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/pylint/pyreverse/diadefslib.py
diff --git a/third_party/pylint/pyreverse/diadefslib.py b/third_party/pylint/pyreverse/diadefslib.py
index 46d0f19a6fde2e195ee1d5b872e957c907912e00..e0dc8cfc7f6ba414d5ff255e97a95d263d662ffb 100644
--- a/third_party/pylint/pyreverse/diadefslib.py
+++ b/third_party/pylint/pyreverse/diadefslib.py
@@ -99,8 +99,8 @@ class DiaDefGenerator(object):
"""return associated nodes of a class node"""
if level == 0:
return
- for ass_nodes in klass_node.instance_attrs_type.values() + \
- klass_node.locals_type.values():
+ for ass_nodes in list(klass_node.instance_attrs_type.values()) + \
+ list(klass_node.locals_type.values()):
for ass_node in ass_nodes:
if isinstance(ass_node, astroid.Instance):
ass_node = ass_node._proxied
@@ -145,7 +145,7 @@ class DefaultDiadefGenerator(LocalsVisitor, DiaDefGenerator):
self.pkgdiagram = None
self.classdiagram = ClassDiagram('classes %s' % node.name, mode)
- def leave_project(self, node):
+ def leave_project(self, node): # pylint: disable=unused-argument
"""leave the astroid.Project node
return the generated diagram definition
@@ -198,7 +198,7 @@ class ClassDiadefGenerator(DiaDefGenerator):
else:
module = project.modules[0]
klass = klass.split('.')[-1]
- klass = module.ilookup(klass).next()
+ klass = next(module.ilookup(klass))
anc_level, ass_level = self._get_levels()
self.extract_classes(klass, anc_level, ass_level)
« no previous file with comments | « third_party/pylint/lint.py ('k') | third_party/pylint/pyreverse/diagrams.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698