patch 8.2.0771: Vim9: cannot call a compiled closure from not compiled code
Problem: Vim9: cannot call a compiled closure from not compiled code.
Solution: Pass funcexe to call_user_func().
diff --git a/src/testdir/test_vim9_func.vim b/src/testdir/test_vim9_func.vim
index c74b4a4..100d86a 100644
--- a/src/testdir/test_vim9_func.vim
+++ b/src/testdir/test_vim9_func.vim
@@ -792,5 +792,15 @@
assert_equal('text!!!', Closure('!!!'))
enddef
+func GetResult(Ref)
+ return a:Ref('some')
+endfunc
+
+def Test_call_closure_not_compiled()
+ let text = 'text'
+ g:Ref = {s -> s .. text}
+ assert_equal('sometext', GetResult(g:Ref))
+enddef
+
" vim: ts=8 sw=2 sts=2 expandtab tw=80 fdm=marker