1
0
forked from VimPlug/jedi

fix problems with set_vars that were no set_vars

This commit is contained in:
David Halter
2013-09-06 15:24:14 +04:30
parent 6f16aaaa19
commit 9bbd73bf86
2 changed files with 14 additions and 2 deletions

View File

@@ -807,6 +807,16 @@ class Statement(Simple):
for stmt in call:
search_calls(stmt.get_commands())
elif isinstance(call, Call):
c = call
# Check if there's an execution in it, if so this is
# not a set_var.
is_execution = False
while c:
if Array.is_type(c.execution, Array.TUPLE):
is_execution = True
c = c.next
if is_execution:
continue
self._set_vars.append(call.name)
for calls, operation in self.assignment_details:

View File

@@ -127,10 +127,12 @@ class A():
A().addition
# should also work before `=`
##? 8 int()
#? 8 int()
A().addition = None
#? 8 int()
A(1).addition = None
a = A()
##? 8 int()
#? 8 int()
a.addition = None