diff options
author | Bram Moolenaar <Bram@vim.org> | 2022-01-12 15:15:27 +0000 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2022-01-12 15:15:27 +0000 |
commit | 5d9826973d9f4c6ffbb5648676bb628660c62906 (patch) | |
tree | 06681a69b48663b7a0b9486bbc4b041dfe5f0603 | |
parent | f479cac084c7ddd9f20944c8978d39f3ef092868 (diff) | |
download | vim-git-5d9826973d9f4c6ffbb5648676bb628660c62906.tar.gz |
patch 8.2.4069: Vim9: import test fails on MS-Windowsv8.2.4069
Problem: Vim9: import test fails on MS-Windows.
Solution: Ignore case. Adjust test to avoid name that only differs in case.
-rw-r--r-- | src/eval.c | 4 | ||||
-rw-r--r-- | src/scriptfile.c | 2 | ||||
-rw-r--r-- | src/testdir/test_vim9_import.vim | 6 | ||||
-rw-r--r-- | src/version.c | 2 |
4 files changed, 8 insertions, 6 deletions
diff --git a/src/eval.c b/src/eval.c index 7a23876f9..08804c092 100644 --- a/src/eval.c +++ b/src/eval.c @@ -906,7 +906,7 @@ get_lval( NULL, TRUE) == -1) { *p = cc; - return FAIL; + return NULL; } *p = cc; } @@ -5903,7 +5903,7 @@ handle_subscript( type_T *type; // Found script from "import {name} as name", script item name must - // follow. + // follow. "rettv->vval.v_number" has the script ID. if (**arg != '.') { if (verbose) diff --git a/src/scriptfile.c b/src/scriptfile.c index 350813934..56186ff07 100644 --- a/src/scriptfile.c +++ b/src/scriptfile.c @@ -2156,7 +2156,7 @@ get_autoload_prefix(scriptitem_T *si) if (p == NULL) return NULL; - prefix = vim_strsave(p); + prefix = strlow_save(p); if (prefix == NULL) return NULL; diff --git a/src/testdir/test_vim9_import.vim b/src/testdir/test_vim9_import.vim index d43012c84..bfc99d531 100644 --- a/src/testdir/test_vim9_import.vim +++ b/src/testdir/test_vim9_import.vim @@ -1203,12 +1203,12 @@ def Test_vim9script_autoload_call() g:result = 'other' enddef END - writefile(lines, 'Xdir/autoload/other.vim') + writefile(lines, 'Xdir/autoload/another.vim') lines =<< trim END vim9script - import autoload 'other.vim' - call other.Getother() + import autoload 'another.vim' + call another.Getother() assert_equal('other', g:result) END CheckScriptSuccess(lines) diff --git a/src/version.c b/src/version.c index 74b03e47c..a931516a9 100644 --- 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 */ /**/ + 4069, +/**/ 4068, /**/ 4067, |