Lines Matching refs:line

22 "  Verify handling of multi-line exprs. and recovery upon the final ';'.
54 " prev_indent = the previous line's indent
55 " prev_lnum = previous line (to start looking on)
57 " stop_at = if non-null, if a matching line is found, gives up!
58 " No recursive previous block analysis: simply look for a valid line
61 " nowhere near the correct indent (e.g., start of line)!
62 " Seems to work OK as it 'starts' with the indent of the /previous/ line.
65 let line = substitute( getline(lnum), g:ada#Comment, '', '' )
67 if a:stop_at != '' && line =~ '^\s*' . a:stop_at && indent(lnum) < a:prev_indent
69 elseif line =~ '^\s*' . a:blockstart
77 " Get previous non-blank/non-comment-only line
79 let line = substitute( getline(lnum), g:ada#Comment, '', '' )
80 if line !~ '^\s*$' && line !~ '^\s*#'
97 " prev_indent = the previous line's indent
98 " prev_lnum = previous line (to start looking on)
103 let line = getline(lnum)
120 " Get previous non-blank/non-comment-only line
122 let line = getline(lnum)
123 let line = substitute( line, g:ada#Comment, '', '' )
124 if line !~ '^\s*$'
140 " (after we've indented due to multi-line statements).
141 " This time, we start searching on the line *before* the one given (which is
148 " Get previous non-blank/non-comment-only line
150 let line = substitute( getline(lnum), g:ada#Comment, '', '' )
152 if line !~ '^\s*$' && line !~ '^\s*#'
160 " Leave indent alone if our ';' line is part of a ';'-delineated
161 " aggregate (e.g., procedure args.) or first line after a block start.
162 if line =~ s:AdaBlockStart || line =~ '(\s*$'
165 if line !~ '[.=(]\s*$'
179 " Find correct indent of a new line based upon what went before
182 " Find a non-blank line above the current line.
187 " Get previous non-blank/non-comment-only/non-cpp line
189 let line = substitute( getline(lnum), g:ada#Comment, '', '' )
190 if line !~ '^\s*$' && line !~ '^\s*#'
199 " Get default indent (from prev. line)
203 " Now check what's on the previous line
204 if line =~ s:AdaBlockStart || line =~ '(\s*$'
207 if line =~ '^\s*\(procedure\|function\|package\)\>.*\<is\s*new\>'
210 elseif line =~ ')\s*;\s*$' || line =~ '^\([^(]*([^)]*)\)*[^(]*;\s*$'
218 elseif line =~ '^\s*\(case\|exception\)\>'
221 elseif line =~ '^\s*end\s*record\>'
225 elseif line =~ '\(^\s*new\>.*\)\@<!)\s*[;,]\s*$'
226 " Revert to indent of line that started this parenthesis pair
231 let ind = indent( prevnonblank( line('.')-1 ) )
236 elseif line =~ '[.=(]\s*$'
239 elseif line =~ '^\s*new\>'
240 " Multiple line generic instantiation ('package blah is\nnew thingy')
242 elseif line =~ ';\s*$'
247 " Check for potential argument list on next line
248 let continuation = (line =~ '[A-Za-z0-9_]\s*$')
251 " Check current line; search for simplistic matching start-of-block
252 let line = getline(v:lnum)
253 if line =~ '^\s*#'
254 " Start of line for ada-pp
256 elseif continuation && line =~ '^\s*('
257 " Don't do this if we've already indented due to the previous line
261 elseif line =~ '^\s*\(begin\|is\)\>'
263 elseif line =~ '^\s*record\>'
265 elseif line =~ '^\s*\(else\|elsif\)\>'
267 elseif line =~ '^\s*when\>'
270 elseif line =~ '^\s*end\>\s*\<if\>'
273 elseif line =~ '^\s*end\>\s*\<loop\>'
276 elseif line =~ '^\s*end\>\s*\<record\>'
279 elseif line =~ '^\s*end\>\s*\<procedure\>'
282 elseif line =~ '^\s*end\>\s*\<case\>'
285 elseif line =~ '^\s*end\>'
288 elseif line =~ '^\s*exception\>'
290 elseif line =~ '^\s*then\>'