mirror of
https://github.com/vim/vim.git
synced 2025-10-03 05:14:07 -04:00
patch 8.2.2053: Vim9: lamba doesn't accept argument types
Problem: Vim9: lamba doesn't accept argument types. Solution: Optionally accept argument types at the script level.
This commit is contained in:
@@ -1828,6 +1828,9 @@ def Test_expr7_lambda()
|
||||
|
||||
assert_equal(false, LambdaUsingArg(0)())
|
||||
assert_equal(true, LambdaUsingArg(1)())
|
||||
|
||||
var res = map([1, 2, 3], {i: number, v: number -> i + v})
|
||||
assert_equal([1, 3, 5], res)
|
||||
END
|
||||
CheckDefAndScriptSuccess(lines)
|
||||
|
||||
|
Reference in New Issue
Block a user