comparison src/testdir/test_lambda.vim @ 9723:80ac9cf77c9b v7.4.2137

commit https://github.com/vim/vim/commit/437bafe4c8a83ed71ee006eda7f54b65a90f0d4c Author: Bram Moolenaar <Bram@vim.org> Date: Mon Aug 1 15:40:54 2016 +0200 patch 7.4.2137 Problem: Using function() with a name will find another function when it is redefined. Solution: Add funcref(). Refer to lambda using a partial. Fix several reference counting issues.
author Christian Brabandt <cb@256bit.org>
date Mon, 01 Aug 2016 15:45:07 +0200
parents 79862f44c647
children 8436bb5134f5
comparison
equal deleted inserted replaced
9722:1557241fd3a7 9723:80ac9cf77c9b
150 delfunction l:Foo 150 delfunction l:Foo
151 return l:Bar 151 return l:Bar
152 endfunction 152 endfunction
153 153
154 let l:F = s:gen() 154 let l:F = s:gen()
155 call assert_fails(':call l:F()', 'E117:') 155 call assert_fails(':call l:F()', 'E933:')
156 endfunction 156 endfunction
157 157
158 function! Test_lambda_scope() 158 function! Test_lambda_scope()
159 function! s:NewCounter() 159 function! s:NewCounter()
160 let c = 0 160 let c = 0