File tree Expand file tree Collapse file tree 1 file changed +8
-12
lines changed Expand file tree Collapse file tree 1 file changed +8
-12
lines changed Original file line number Diff line number Diff line change @@ -138,25 +138,21 @@ endfunction
138138" Find possible indent(s) of the block starter that matches the current line.
139139function ! s: find_start_of_block (lnum, types, multiple)
140140 let r = []
141- let types = copy (a: types )
142141 let re = ' \V\^\s\*\(' .join (a: types , ' \|' ).' \)\>'
143142 let lnum = a: lnum
144143 let last_indent = indent (lnum) + 1
145144 while lnum > 0 && last_indent > 0
146145 let indent = indent (lnum)
147146 if indent < last_indent
148- for type in types
149- let re = ' \v^\s*' .type .' >'
150- if getline (lnum) = ~# re
151- if ! a: multiple
152- return [indent ]
153- endif
154- if index (r , indent ) == -1
155- let r += [indent ]
156- endif
147+ if getline (lnum) = ~# re
148+ if ! a: multiple
149+ return [indent ]
157150 endif
158- endfor
159- let last_indent = indent (lnum)
151+ if index (r , indent ) == -1
152+ let r += [indent ]
153+ endif
154+ let last_indent = indent
155+ endif
160156 endif
161157 let lnum = prevnonblank (lnum - 1 )
162158 endwhile
You can’t perform that action at this time.
0 commit comments