We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent b55d5ba commit 369fc01Copy full SHA for 369fc01
1 file changed
autoload/sj/python.vim
@@ -246,6 +246,7 @@ function! sj#python#JoinAssignment()
246
endif
247
248
let start_line = line('.')
249
+ let start_line_indent = indent('.')
250
let [first_variable, first_value] = split(getline('.'), assignment_pattern)
251
let variables = [ first_variable ]
252
let values = [ first_value ]
@@ -255,7 +256,9 @@ function! sj#python#JoinAssignment()
255
256
while next_line > 0 && next_line <= line('$')
257
exe next_line
258
- if search(assignment_pattern, 'W', line('.')) <= 0
259
+ if indent('.') != start_line_indent
260
+ break
261
+ elseif search(assignment_pattern, 'W', line('.')) <= 0
262
break
263
else
264
let [variable, value] = split(getline(next_line), assignment_pattern)
0 commit comments