]> git.ipfire.org Git - thirdparty/vim.git/commitdiff
patch 8.2.4117: Vim9: wrong white space error after using imported item v8.2.4117
authorBram Moolenaar <Bram@vim.org>
Sun, 16 Jan 2022 21:18:53 +0000 (21:18 +0000)
committerBram Moolenaar <Bram@vim.org>
Sun, 16 Jan 2022 21:18:53 +0000 (21:18 +0000)
Problem:    Vim9: wrong white space error after using imported item.
Solution:   Don't skip over white space. (closes #9544)

src/eval.c
src/testdir/test_vim9_import.vim
src/version.c

index c8907defd0b0f6a6eca836e8cf3e3796e3925bb1..a21fbba8515941190e002905e19c34e51f5b8d13 100644 (file)
@@ -6001,7 +6001,6 @@ handle_subscript(
            idx = find_exported(rettv->vval.v_number, exp_name, &ufunc, &type,
                                                  evalarg->eval_cctx, verbose);
            **arg = cc;
-           *arg = skipwhite(*arg);
 
            if (idx < 0 && ufunc == NULL)
            {
index 6c6911a1e4fa41f49516c3cd3db3c0869de36a9f..36caf70068a05b78ed1089b3390f67adb7683396 100644 (file)
@@ -69,6 +69,7 @@ def Test_vim9_import_export()
 
     g:imported_name = expo.exp_name
     expo.exp_name ..= ' Doe'
+    expo.exp_name = expo.exp_name .. ' Maar'
     g:imported_name_appended = expo.exp_name
     g:exported_later = expo.exported
 
@@ -97,7 +98,7 @@ def Test_vim9_import_export()
   assert_equal('Exported', g:imported_func)
   assert_equal('Exported', g:funcref_result)
   assert_equal('John', g:imported_name)
-  assert_equal('John Doe', g:imported_name_appended)
+  assert_equal('John Doe Maar', g:imported_name_appended)
   assert_false(exists('g:name'))
 
   Undo_export_script_lines()
index feedd8f6e99be3a18b8d2c7b70bfff4fa340635e..1c367e68e92dee6a4410a91f8aaa68629a8ff21b 100644 (file)
@@ -750,6 +750,8 @@ static char *(features[]) =
 
 static int included_patches[] =
 {   /* Add new patch number below this line */
+/**/
+    4117,
 /**/
     4116,
 /**/