0
0
mirror of https://github.com/vim/vim.git synced 2025-10-20 08:14:18 -04:00

patch 8.2.3783: confusing error for using a variable as a function

Problem:    Confusing error for using a variable as a function.
Solution:   If a function is not found but there is a variable, give a more
            useful error. (issue #9310)
This commit is contained in:
Bram Moolenaar
2021-12-11 16:14:07 +00:00
parent 052ff291d7
commit 2ef9156b42
9 changed files with 51 additions and 19 deletions

View File

@@ -2234,6 +2234,12 @@ func Test_call()
call call(test_null_partial(), [])
call assert_fails('call test_null_function()()', 'E1192:')
call assert_fails('call test_null_partial()()', 'E117:')
let lines =<< trim END
let Time = 'localtime'
call Time()
END
CheckScriptFailure(lines, 'E1085:')
endfunc
func Test_char2nr()