Skip to content

Commit d058e58

Browse files
author
skywind3000
committed
resolve name conflict
1 parent ec01510 commit d058e58

File tree

3 files changed

+9
-6
lines changed

3 files changed

+9
-6
lines changed

autoload/quickui/context.vim

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -267,8 +267,9 @@ function! s:popup_exit(winid, code)
267267
let g:quickui#context#cursor = hwnd.index
268268
let redrawed = 0
269269
if has_key(hwnd.opts, 'callback')
270-
let F = function(hwnd.opts.callback)
271-
call F(code)
270+
let l:F = function(hwnd.opts.callback)
271+
call l:F(code)
272+
unlet l:F
272273
endif
273274
silent! call popup_hide(a:winid)
274275
if code >= 0 && code < len(hwnd.items)

autoload/quickui/listbox.vim

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -264,8 +264,9 @@ function! s:popup_exit(winid, code)
264264
silent! call popup_hide(a:winid)
265265
let g:quickui#listbox#current = hwnd
266266
if has_key(hwnd.opts, 'callback')
267-
let F = function(hwnd.opts.callback)
268-
call F(code)
267+
let l:F = function(hwnd.opts.callback)
268+
call l:F(code)
269+
unlet l:F
269270
endif
270271
if code >= 0 && code < hwnd.items.nrows
271272
let cmd = hwnd.items.cmds[code]

autoload/quickui/textbox.vim

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -149,8 +149,9 @@ function! s:popup_exit(winid, code)
149149
let g:quickui#textbox#current = local
150150
call quickui#core#popup_clear(a:winid)
151151
if has_key(local, 'callback')
152-
let F = function(local.callback)
153-
call F(topline)
152+
let l:F = function(local.callback)
153+
call l:F(topline)
154+
unlet l:F
154155
endif
155156
endfunc
156157

0 commit comments

Comments
 (0)