changeset 28113:9ef1bbe6707e v8.2.4581

patch 8.2.4581: null types not fully tested Commit: https://github.com/vim/vim/commit/d597ab00d799aa078be32e6677e01a7582106105 Author: Bram Moolenaar <Bram@vim.org> Date: Wed Mar 16 17:56:33 2022 +0000 patch 8.2.4581: null types not fully tested Problem: Null types not fully tested. Solution: Add some more tests using null types.
author Bram Moolenaar <Bram@vim.org>
date Wed, 16 Mar 2022 19:00:04 +0100
parents e76b1fa085ca
children 8510390872d6
files src/testdir/test_vim9_expr.vim src/version.c
diffstat 2 files changed, 12 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/src/testdir/test_vim9_expr.vim
+++ b/src/testdir/test_vim9_expr.vim
@@ -2091,6 +2091,11 @@ def Test_expr8_list()
       var llstring: list<list<string>> = [['text'], []]
       llstring = [[], ['text']]
       llstring = [[], []]
+
+      var ls = [null_string]
+      assert_equal('list<string>', typename(ls))
+      var lb = [null_blob]
+      assert_equal('list<blob>', typename(lb))
   END
   v9.CheckDefAndScriptSuccess(lines)
 
@@ -2608,6 +2613,11 @@ def Test_expr8_dict()
       # comment to start fold is OK
       var x1: number #{{ fold
       var x2 = 9 #{{ fold
+
+      var ds = {k: null_string}
+      assert_equal('dict<string>', typename(ds))
+      var dl = {a: null_list}
+      assert_equal('dict<list<unknown>>', typename(dl))
   END
   v9.CheckDefAndScriptSuccess(lines)
  
--- a/src/version.c
+++ b/src/version.c
@@ -751,6 +751,8 @@ static char *(features[]) =
 static int included_patches[] =
 {   /* Add new patch number below this line */
 /**/
+    4581,
+/**/
     4580,
 /**/
     4579,