forked from VimPlug/jedi
Rename next_sibling and prev_sibling.
This commit is contained in:
@@ -343,7 +343,7 @@ def _name_to_types(evaluator, name, scope):
|
||||
# TODO an exception can also be a tuple. Check for those.
|
||||
# TODO check for types that are not classes and add it to
|
||||
# the static analysis report.
|
||||
exceptions = evaluator.eval_element(name.prev_sibling().prev_sibling())
|
||||
exceptions = evaluator.eval_element(name.get_previous_sibling().get_previous_sibling())
|
||||
types = set(chain.from_iterable(evaluator.execute(t) for t in exceptions))
|
||||
else:
|
||||
if typ.isinstance(er.Function):
|
||||
|
||||
@@ -162,8 +162,8 @@ class Instance(use_metaclass(CachedMetaClass, Executed)):
|
||||
sub = self._get_method_execution(sub)
|
||||
for name_list in sub.names_dict.values():
|
||||
for name in name_list:
|
||||
if name.value == self_name and name.prev_sibling() is None:
|
||||
trailer = name.next_sibling()
|
||||
if name.value == self_name and name.get_previous_sibling() is None:
|
||||
trailer = name.get_next_sibling()
|
||||
if tree.is_node(trailer, 'trailer') \
|
||||
and len(trailer.children) == 2 \
|
||||
and trailer.children[0] == '.':
|
||||
|
||||
Reference in New Issue
Block a user