patch 8.2.3266: Vim9: assignment with two indexes may check next line
Problem: Vim9: assignment with two indexes may check next line.
Solution: Limit the number of lines to avoid checking the next line when
assiging to a LHS subscript. (closes #8660)
diff --git a/src/testdir/test_vim9_assign.vim b/src/testdir/test_vim9_assign.vim
index 97983ef..c104059 100644
--- a/src/testdir/test_vim9_assign.vim
+++ b/src/testdir/test_vim9_assign.vim
@@ -466,6 +466,12 @@
d3.one.two.three = 123
assert_equal({one: {two: {three: 123}}}, d3)
+ # should not read the next line when generating "a.b"
+ var a = {}
+ a.b = {}
+ a.b.c = {}
+ ->copy()
+
lines =<< trim END
var d3: dict<dict<number>>
d3.one = {}