From d79f41149f747b83210804ff379ddbd8aaf3ab5b Mon Sep 17 00:00:00 2001 From: Daniel Hahler Date: Tue, 12 May 2015 21:21:33 +0200 Subject: [PATCH] Fix wrong call of `goto` in `do_rename` This was overseen in dd33e38. This is the main fix for https://github.com/davidhalter/jedi-vim/issues/41. --- jedi_vim.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/jedi_vim.py b/jedi_vim.py index 331e661..3deb89c 100644 --- a/jedi_vim.py +++ b/jedi_vim.py @@ -476,8 +476,8 @@ def do_rename(replace, orig = None): saved_tab = int(vim_eval('tabpagenr()')) saved_win = int(vim_eval('winnr()')) - temp_rename = goto(is_related_name=True, no_output=True) - # sort the whole thing reverse (positions at the end of the line + temp_rename = goto(mode="related_name", no_output=True) + # Sort the whole thing reverse (positions at the end of the line # must be first, because they move the stuff before the position). temp_rename = sorted(temp_rename, reverse=True, key=lambda x: (x.module_path, x.start_pos))