1
0
forked from VimPlug/jedi

Completely remove names_dicts from the diff parser.

This commit is contained in:
Dave Halter
2016-12-17 17:15:44 +01:00
parent 589e1906e4
commit 5c52c7fb45
6 changed files with 11 additions and 64 deletions

View File

@@ -717,7 +717,7 @@ class Scope(BaseNode, DocstringMixin):
:param start_pos: The position (line and column) of the scope.
:type start_pos: tuple(int, int)
"""
__slots__ = ('names_dict',)
__slots__ = ()
def __init__(self, children):
super(Scope, self).__init__(children)
@@ -1648,17 +1648,6 @@ class CompFor(BaseNode):
def is_scope(self):
return True
@property
def names_dict(self):
dct = {}
for name in self.get_defined_names():
arr = dct.setdefault(name.value, [])
arr.append(name)
return dct
def names_dicts(self, search_global):
yield self.names_dict
def get_defined_names(self):
return _defined_names(self.children[1])