diff src/testdir/test55.in @ 6166:0a42938f449c v7.4.419

updated for version 7.4.419 Problem: Whan part of a list is locked it's possible to make changes. Solution: Check if any of the list items is locked before make a change. (ZyX)
author Bram Moolenaar <bram@vim.org>
date Fri, 29 Aug 2014 09:46:10 +0200
parents f9ec944e4474
children 9fbb9c60ab41
line wrap: on
line diff
--- a/src/testdir/test55.in
+++ b/src/testdir/test55.in
@@ -282,6 +282,21 @@ let l = [0, 1, 2, 3]
 :    $put =ps
 :  endfor
 :endfor
+:unlet l
+:let l = [1, 2, 3, 4]
+:lockvar! l
+:$put =string(l)
+:unlockvar l[1]
+:unlet l[0:1]
+:$put =string(l)
+:unlet l[1:2]
+:$put =string(l)
+:unlockvar l[1]
+:let l[0:1] = [0, 1]
+:$put =string(l)
+:let l[1:2] = [0, 1]
+:$put =string(l)
+:unlet l
 :" :lockvar/islocked() triggering script autoloading
 :set rtp+=./sautest
 :lockvar g:footest#x