forked from VimPlug/jedi
remove old return statements
This commit is contained in:
@@ -758,14 +758,14 @@ class Statement(Simple):
|
|||||||
tok_temp, type(tok_temp))
|
tok_temp, type(tok_temp))
|
||||||
raise
|
raise
|
||||||
else:
|
else:
|
||||||
if tok in ['return', 'yield'] or level == 0 and \
|
if level == 0 and tok.endswith('=') \
|
||||||
tok.endswith('=') and not tok in ['>=', '<=', '==', '!=']:
|
and not tok in ['>=', '<=', '==', '!=']:
|
||||||
# This means, there is an assignment here.
|
# This means, there is an assignment here.
|
||||||
|
|
||||||
# Add assignments, which can be more than one
|
# Add assignments, which can be more than one
|
||||||
self._assignment_details.append((tok, top))
|
self._assignment_details.append((tok, top))
|
||||||
# All these calls wouldn't be important if nonlocal would
|
# All these calls wouldn't be important if nonlocal would
|
||||||
# exist. -> Initialize the first item again.
|
# exist. -> Initialize the first items again.
|
||||||
top = result = Array(start_pos, Array.NOARRAY, self)
|
top = result = Array(start_pos, Array.NOARRAY, self)
|
||||||
level = 0
|
level = 0
|
||||||
close_brackets = False
|
close_brackets = False
|
||||||
|
|||||||
Reference in New Issue
Block a user