Mercurial > vim
comparison src/testdir/test_unlet.vim @ 20128:0b35a7ffceb2 v8.2.0619
patch 8.2.0619: null dict is not handled like an empty dict
Commit: https://github.com/vim/vim/commit/ea04a6e8baff2f27da7cdd54bf70a5525994f76d
Author: Bram Moolenaar <Bram@vim.org>
Date: Thu Apr 23 13:38:02 2020 +0200
patch 8.2.0619: null dict is not handled like an empty dict
Problem: Null dict is not handled like an empty dict.
Solution: Fix the code and add tests. (Yegappan Lakshmanan, closes https://github.com/vim/vim/issues/5968)
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Thu, 23 Apr 2020 13:45:04 +0200 |
parents | b3e93a05c3ca |
children |
comparison
equal
deleted
inserted
replaced
20127:a62c4185482f | 20128:0b35a7ffceb2 |
---|---|
25 call assert_fails('unlet v[:]', 'E719:') | 25 call assert_fails('unlet v[:]', 'E719:') |
26 let l = [] | 26 let l = [] |
27 call assert_fails("unlet l['k'", 'E111:') | 27 call assert_fails("unlet l['k'", 'E111:') |
28 let d = {'k' : 1} | 28 let d = {'k' : 1} |
29 call assert_fails("unlet d.k2", 'E716:') | 29 call assert_fails("unlet d.k2", 'E716:') |
30 call assert_fails("unlet {a};", 'E488:') | |
30 endfunc | 31 endfunc |
31 | 32 |
32 func Test_unlet_env() | 33 func Test_unlet_env() |
33 let envcmd = has('win32') ? 'set' : 'env' | 34 let envcmd = has('win32') ? 'set' : 'env' |
34 | 35 |