comparison src/testdir/test_vim9_func.vim @ 22371:15003353a464 v8.2.1734

patch 8.2.1734: Vim9: cannot use a funcref for a closure twice Commit: https://github.com/vim/vim/commit/148ce7ae62e92ecf6487a4ba5902ddb7e699074b Author: Bram Moolenaar <Bram@vim.org> Date: Wed Sep 23 21:57:23 2020 +0200 patch 8.2.1734: Vim9: cannot use a funcref for a closure twice Problem: Vim9: cannot use a funcref for a closure twice. Solution: Instead of putting the funcref on the stack use a growarray on the execution context.
author Bram Moolenaar <Bram@vim.org>
date Wed, 23 Sep 2020 22:00:06 +0200
parents b66a2e046c2e
children df1d7a560b35
comparison
equal deleted inserted replaced
22370:9a06648f05d3 22371:15003353a464
1365 timer_start(0, {-> var}) 1365 timer_start(0, {-> var})
1366 endfor 1366 endfor
1367 enddef 1367 enddef
1368 Func() 1368 Func()
1369 END 1369 END
1370 CheckScriptFailure(lines, 'Multiple closures not supported yet') 1370 CheckScriptSuccess(lines)
1371 enddef 1371 enddef
1372 1372
1373 def Test_sort_return_type() 1373 def Test_sort_return_type()
1374 let res: list<number> 1374 let res: list<number>
1375 res = [1, 2, 3]->sort() 1375 res = [1, 2, 3]->sort()