mirror of
https://github.com/vim/vim.git
synced 2025-09-29 04:34:16 -04:00
patch 8.2.0981: Vim9: cannot compile "[var, var] = list"
Problem: Vim9: cannot compile "[var, var] = list". Solution: Implement list assignment.
This commit is contained in:
@@ -223,6 +223,14 @@ def Test_assignment_default()
|
||||
assert_equal(5678, nr)
|
||||
enddef
|
||||
|
||||
def Test_assignment_var_list()
|
||||
let v1: string
|
||||
let v2: string
|
||||
[v1, v2] = ['one', 'two']
|
||||
assert_equal('one', v1)
|
||||
assert_equal('two', v2)
|
||||
enddef
|
||||
|
||||
def Mess(): string
|
||||
v:foldstart = 123
|
||||
return 'xxx'
|
||||
|
Reference in New Issue
Block a user