summaryrefslogtreecommitdiffstats
path: root/src/testdir/test_let.vim
diff options
context:
space:
mode:
authorYegappan Lakshmanan <yegappan@yahoo.com>2024-04-14 23:21:02 +0200
committerChristian Brabandt <cb@256bit.org>2024-04-14 23:21:02 +0200
commitf01493c55062c01b1cdf9b1e946577f4d1bdddf3 (patch)
tree3f4ed5607440c2000644374866dd77850a6688ba /src/testdir/test_let.vim
parent0d87e3c711b46be67cf8f014cc0bca21431599c0 (diff)
patch 9.1.0329: String interpolation fails for Dict typev9.1.0329
Problem: String interpolation fails for Dict type Solution: Support Dict data type properly, also support :put =Dict (without having to convert it to string() first) (Yegappan Lakshmanan) fixes: #14529 closes: #14541 Signed-off-by: Yegappan Lakshmanan <yegappan@yahoo.com> Signed-off-by: Christian Brabandt <cb@256bit.org>
Diffstat (limited to 'src/testdir/test_let.vim')
-rw-r--r--src/testdir/test_let.vim7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/testdir/test_let.vim b/src/testdir/test_let.vim
index 17f78ea347..fec02731c4 100644
--- a/src/testdir/test_let.vim
+++ b/src/testdir/test_let.vim
@@ -689,6 +689,13 @@ END
END
call assert_equal(['let a = {abc}', 'let b = X', 'let c = {'], code)
+ " Evaluate a dictionary
+ let d1 = #{a: 10, b: 'ss', c: {}}
+ let code =<< eval trim END
+ let d2 = {d1}
+ END
+ call assert_equal(["let d2 = {'a': 10, 'b': 'ss', 'c': {}}"], code)
+
let code = 'xxx'
let code =<< eval trim END
let n = {5 +