diff options
author | Bram Moolenaar <Bram@vim.org> | 2020-09-28 21:48:16 +0200 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2020-09-28 21:48:16 +0200 |
commit | d58a3bf7dac8d53faf42e13cc1152b110f12c404 (patch) | |
tree | 8718d3d947d850a9ee4492dbf98a4b2150c36a1f /runtime/indent | |
parent | b45cd36bd90f71e4a35b1ef1f75a3bedef6d8bac (diff) |
Update runtime files.
Diffstat (limited to 'runtime/indent')
-rw-r--r-- | runtime/indent/vim.vim | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/runtime/indent/vim.vim b/runtime/indent/vim.vim index 3809943388..4b0867d88a 100644 --- a/runtime/indent/vim.vim +++ b/runtime/indent/vim.vim @@ -1,7 +1,7 @@ " Vim indent file " Language: Vim script " Maintainer: Bram Moolenaar <Bram@vim.org> -" Last Change: 2020 Jul 19 +" Last Change: 2020 Sep 27 " Only load this indent file when no other was loaded. if exists("b:did_indent") @@ -10,7 +10,7 @@ endif let b:did_indent = 1 setlocal indentexpr=GetVimIndent() -setlocal indentkeys+==end,=},=else,=cat,=fina,=END,0\\,0=\"\\\ +setlocal indentkeys+==end,=},=else,=cat,=finall,=END,0\\,0=\"\\\ setlocal indentkeys-=0# let b:undo_indent = "setl indentkeys< indentexpr<" @@ -93,7 +93,7 @@ function GetVimIndentIntern() else " A line starting with :au does not increment/decrement indent. if prev_text !~ '^\s*au\%[tocmd]' - let i = match(prev_text, '\(^\||\)\s*\({\|\(if\|wh\%[ile]\|for\|try\|cat\%[ch]\|fina\%[lly]\|fu\%[nction]\|def\|el\%[seif]\)\>\)') + let i = match(prev_text, '\(^\||\)\s*\(export\s\+\)\?\({\|\(if\|wh\%[ile]\|for\|try\|cat\%[ch]\|fina\|finall\%[y]\|fu\%[nction]\|def\|el\%[seif]\)\>\)') if i >= 0 let ind += shiftwidth() if strpart(prev_text, i, 1) == '|' && has('syntax_items') @@ -117,7 +117,7 @@ function GetVimIndentIntern() " Subtract a 'shiftwidth' on a :endif, :endwhile, :catch, :finally, :endtry, " :endfun, :enddef, :else and :augroup END. - if cur_text =~ '^\s*\(ene\@!\|}\|cat\|fina\|el\|aug\%[roup]\s\+[eE][nN][dD]\)' + if cur_text =~ '^\s*\(ene\@!\|}\|cat\|finall\|el\|aug\%[roup]\s\+[eE][nN][dD]\)' let ind = ind - shiftwidth() endif |