mirror of
https://github.com/vim/vim.git
synced 2025-07-25 10:54:51 -04:00
patch 8.2.4161: Vim9: warning for missing white space after imported variable
Problem: Vim9: warning for missing white space after imported variable. Solution: Do not skip white space. (closes #9567)
This commit is contained in:
parent
4ede01f188
commit
21f0d6cbca
@ -67,6 +67,11 @@ def Test_vim9_import_export()
|
|||||||
enddef
|
enddef
|
||||||
g:funcref_result = GetExported()
|
g:funcref_result = GetExported()
|
||||||
|
|
||||||
|
def GetName(): string
|
||||||
|
return expo.exp_name .. 'son'
|
||||||
|
enddef
|
||||||
|
g:long_name = GetName()
|
||||||
|
|
||||||
g:imported_name = expo.exp_name
|
g:imported_name = expo.exp_name
|
||||||
expo.exp_name ..= ' Doe'
|
expo.exp_name ..= ' Doe'
|
||||||
expo.exp_name = expo.exp_name .. ' Maar'
|
expo.exp_name = expo.exp_name .. ' Maar'
|
||||||
@ -98,6 +103,7 @@ def Test_vim9_import_export()
|
|||||||
assert_equal('Exported', g:imported_func)
|
assert_equal('Exported', g:imported_func)
|
||||||
assert_equal('Exported', g:funcref_result)
|
assert_equal('Exported', g:funcref_result)
|
||||||
assert_equal('John', g:imported_name)
|
assert_equal('John', g:imported_name)
|
||||||
|
assert_equal('Johnson', g:long_name)
|
||||||
assert_equal('John Doe Maar', g:imported_name_appended)
|
assert_equal('John Doe Maar', g:imported_name_appended)
|
||||||
assert_false(exists('g:name'))
|
assert_false(exists('g:name'))
|
||||||
|
|
||||||
@ -109,7 +115,7 @@ def Test_vim9_import_export()
|
|||||||
unlet g:exported_i2
|
unlet g:exported_i2
|
||||||
unlet g:exported_later
|
unlet g:exported_later
|
||||||
unlet g:imported_func
|
unlet g:imported_func
|
||||||
unlet g:imported_name g:imported_name_appended
|
unlet g:imported_name g:long_name g:imported_name_appended
|
||||||
delete('Ximport.vim')
|
delete('Ximport.vim')
|
||||||
|
|
||||||
# similar, with line breaks
|
# similar, with line breaks
|
||||||
|
@ -750,6 +750,8 @@ static char *(features[]) =
|
|||||||
|
|
||||||
static int included_patches[] =
|
static int included_patches[] =
|
||||||
{ /* Add new patch number below this line */
|
{ /* Add new patch number below this line */
|
||||||
|
/**/
|
||||||
|
4161,
|
||||||
/**/
|
/**/
|
||||||
4160,
|
4160,
|
||||||
/**/
|
/**/
|
||||||
|
@ -321,7 +321,6 @@ compile_load_scriptvar(
|
|||||||
cctx, TRUE);
|
cctx, TRUE);
|
||||||
}
|
}
|
||||||
*p = cc;
|
*p = cc;
|
||||||
p = skipwhite(p);
|
|
||||||
*end = p;
|
*end = p;
|
||||||
if (done)
|
if (done)
|
||||||
return res;
|
return res;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user