mirror of
https://github.com/davidhalter/jedi-vim.git
synced 2025-12-06 10:54:22 +08:00
@@ -293,10 +293,7 @@ def goto(mode="goto", no_output=False):
|
||||
"""
|
||||
script = get_script()
|
||||
if mode == "goto":
|
||||
definitions = [x for x in script.goto_definitions()
|
||||
if not x.in_builtin_module()]
|
||||
if not definitions:
|
||||
definitions = script.goto_assignments()
|
||||
definitions = script.goto_assignments(follow_imports=True)
|
||||
elif mode == "related_name":
|
||||
definitions = script.usages()
|
||||
elif mode == "definition":
|
||||
|
||||
@@ -22,8 +22,8 @@ describe 'goto simple'
|
||||
|
||||
it 'goto definitions'
|
||||
normal \d
|
||||
Expect line('.') == 1
|
||||
Expect col('.') == 5
|
||||
Expect line('.') == 2
|
||||
Expect col('.') == 1
|
||||
end
|
||||
|
||||
it 'goto assignments'
|
||||
|
||||
Reference in New Issue
Block a user