Skip to content

Commit

Permalink
Remove unused code
Browse files Browse the repository at this point in the history
  • Loading branch information
liuchengxu committed Aug 10, 2023
1 parent 80712f0 commit 4f5627c
Showing 1 changed file with 0 additions and 20 deletions.
20 changes: 0 additions & 20 deletions autoload/clap/state.vim
Original file line number Diff line number Diff line change
Expand Up @@ -236,26 +236,6 @@ function! clap#state#set_input(new) abort
call clap#api#win_execute(g:clap.input.winid, 'call cursor(1, 1000)')
endfunction

" Returns the cached source tmp file.
"
" Write the providers whose `source` is list-style into a tempfile.
function! clap#state#into_tempfile(source_list) abort
if has_key(g:clap.provider, 'source_tempfile')
let tmp = g:clap.provider.source_tempfile
return tmp
else
let tmp = tempname()
if writefile(a:source_list, tmp) == 0
call add(g:clap.tmps, tmp)
let g:clap.provider.source_tempfile = tmp
return tmp
else
call g:clap.abort('Fail to write source to a temp file')
return ''
endif
endif
endfunction

function! s:unlet_vars(vars) abort
for var in a:vars
if exists(var)
Expand Down

0 comments on commit 4f5627c

Please sign in to comment.