mirror of
https://github.com/neovim/neovim.git
synced 2024-12-29 14:41:06 -07:00
indent/lua.vim: fix indent of nested elseif
This commit is contained in:
commit
68717132b1
@ -54,7 +54,7 @@ function! GetLuaIndent()
|
||||
|
||||
" Subtract a 'shiftwidth' on end, else (and elseif), until and '}'
|
||||
" This is the part that requires 'indentkeys'.
|
||||
let midx = match(getline(v:lnum), '^\s*\%(end\>\|else\>\|until\>\|}\)')
|
||||
let midx = match(getline(v:lnum), '^\s*\%(end\>\|else\>\|elseif\>\|until\>\|}\)')
|
||||
if midx != -1 && synIDattr(synID(v:lnum, midx + 1, 1), "name") != "luaComment"
|
||||
let ind = ind - &shiftwidth
|
||||
endif
|
||||
|
Loading…
Reference in New Issue
Block a user