summaryrefslogtreecommitdiff
path: root/src/testdir/test_listdict.vim
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2021-06-26 15:00:59 +0200
committerBram Moolenaar <Bram@vim.org>2021-06-26 15:00:59 +0200
commit3a3b10e87a10dd0bc355618dbfc4a0a6c828aad7 (patch)
treee74e88f7d0cbf28ff9d9af3ae9a371348656cdfa /src/testdir/test_listdict.vim
parent4d5dfe20839e9d13c95eaf4254467f952653b042 (diff)
downloadvim-git-3a3b10e87a10dd0bc355618dbfc4a0a6c828aad7.tar.gz
patch 8.2.3055: strange error for assigning to "x.key" on non-dictionaryv8.2.3055
Problem: Strange error for assigning to "x.key" on non-dictionary. Solution: Add a specific error message. (closes #8451)
Diffstat (limited to 'src/testdir/test_listdict.vim')
-rw-r--r--src/testdir/test_listdict.vim3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/testdir/test_listdict.vim b/src/testdir/test_listdict.vim
index 8351acb41..96debd64d 100644
--- a/src/testdir/test_listdict.vim
+++ b/src/testdir/test_listdict.vim
@@ -294,6 +294,9 @@ func Test_dict_assign()
let d.1 = 1
let d._ = 2
call assert_equal({'1': 1, '_': 2}, d)
+
+ let n = 0
+ call assert_fails('let n.key = 3', 'E1203: Dot can only be used on a dictionary: n.key = 3')
endfunc
" Function in script-local List or Dict