- Re-Fixed wrong indentation when 'expandtab'.

This commit is contained in:
Shougo Matsushita 2012-09-27 14:42:37 +09:00
parent 8e7e2d4ee4
commit 7f3241815d
1 changed files with 1 additions and 1 deletions

View File

@ -635,7 +635,7 @@ function! s:indent_snippet(begin, end)"{{{
" Delete head tab character.
let current_line = substitute(getline('.'), '^\t', '', '')
if &l:expandtab
if &l:expandtab && current_line =~ '^\t\+'
" Expand tab.
cal setline('.', substitute(current_line,
\ '^\t\+', base_indent . repeat(' ', &shiftwidth *