1
0
forked from VimPlug/jedi

goto before assignments should still work, 305

This commit is contained in:
David Halter
2013-09-06 14:56:35 +04:30
parent 95bac43840
commit fcc6c4d811
2 changed files with 6 additions and 5 deletions
+3 -2
View File
@@ -441,8 +441,9 @@ class Script(object):
definitions = follow_inexistent_imports(defs)
if isinstance(user_stmt, pr.Statement):
c = user_stmt.get_commands()
if c and not isinstance(c[0], (str, unicode)) and \
c[0].start_pos > self._pos:
if c and not isinstance(c[0], (str, unicode)) \
and c[0].start_pos > self._pos \
and not re.search(r'\.\w+$', goto_path):
# The cursor must be after the start, otherwise the
# statement is just an assignee.
definitions = [user_stmt]