File tree Expand file tree Collapse file tree 1 file changed +3
-2
lines changed Expand file tree Collapse file tree 1 file changed +3
-2
lines changed Original file line number Diff line number Diff line change @@ -145,7 +145,8 @@ function s:GetMSL(lnum, in_one_line_scope)
145
145
" Otherwise, terminate search as we have found our MSL already.
146
146
let line = getline (lnum)
147
147
let col = match (line , s: msl_regex ) + 1
148
- if (col > 0 && ! s: IsInStringOrComment (lnum, col )) || s: IsInString (lnum, strlen (line ))
148
+ let colprev = s: Match (msl, s: operator_first )
149
+ if ((col > 0 && ! s: IsInStringOrComment (lnum, col )) || s: IsInString (lnum, strlen (line )) || colprev)
149
150
let msl = lnum
150
151
else
151
152
" Don't use lines that are part of a one line scope as msl unless the
@@ -390,7 +391,7 @@ function GetJavascriptIndent()
390
391
if mnum > 0 && s: Match (mnum, s: operator_first )
391
392
return indent (mnum)
392
393
end
393
- else
394
+ elseif counts[ 0 ] != ' 1 ' && counts[ 1 ] != ' 1 ' && counts[ 2 ] != ' 1 '
394
395
" otherwise, indent 1 level
395
396
return indent (prevline) + s: sw ()
396
397
end
You can’t perform that action at this time.
0 commit comments