Fix duplicate closing delimiter after <CR>

This commit is contained in:
Israel Chauca Fuentes
2010-05-12 19:57:48 -05:00
parent 72e639ff1a
commit ed672dd39b
3 changed files with 24 additions and 11 deletions

View File

@@ -494,8 +494,12 @@ function! delimitMate#Finish() " {{{
let b:delimitMate_buffer = []
let line = getline('.')
let col = col('.') -2
"echom 'col: ' . col . '-' . line[:col] . "|" . line[col+len+1:] . '%' . buffer
call setline('.', line[:col] . line[col+len+1:])
echom 'col: ' . col . '-' . line[:col] . "|" . line[col+len+1:] . '%' . buffer
if col < 0
call setline('.', line[col+len+1:])
else
call setline('.', line[:col] . line[col+len+1:])
endif
let i = 1
let lefts = "\<Left>"
while i < len