aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--vim/plugin/textobj.vim8
1 files changed, 6 insertions, 2 deletions
diff --git a/vim/plugin/textobj.vim b/vim/plugin/textobj.vim
index 85381df..e8fd804 100644
--- a/vim/plugin/textobj.vim
+++ b/vim/plugin/textobj.vim
@@ -29,10 +29,14 @@ function Textobj(char, callback)
let objlength -= 1
endif
call cursor(startline, startcol)
- exe 'normal! '.a:operator.objlength.' '
+ if a:operator == 'c'
+ let operator = 'd'
+ else
+ let operator = a:operator
+ end
+ exe 'normal! '.operator.objlength.' '
if a:operator == 'c'
- normal! l
startinsert
elseif a:operator == 'v'
exe "normal! \<BS>"