forked from aniani/vim
patch 8.2.1423: Vim9: find global function when looking for script-local
Problem: Vim9: find global function when looking for script-local. Solution: Don't strip prefix if name starts with "s:". (closes #6688)
This commit is contained in:
@@ -203,6 +203,15 @@ def Test_global_local_function()
|
||||
assert_equal('local', Func())
|
||||
END
|
||||
CheckScriptSuccess(lines)
|
||||
|
||||
lines =<< trim END
|
||||
vim9script
|
||||
def g:Funcy()
|
||||
echo 'funcy'
|
||||
enddef
|
||||
s:Funcy()
|
||||
END
|
||||
CheckScriptFailure(lines, 'E117:')
|
||||
enddef
|
||||
|
||||
func TakesOneArg(arg)
|
||||
|
||||
Reference in New Issue
Block a user