improve perf by not calling get_position() (#822)

This commit is contained in:
Prabir Shrestha
2020-05-24 15:04:23 -07:00
committed by GitHub
parent 3d0153bcf9
commit ed85fbcb36

View File

@@ -250,7 +250,7 @@ endfunction
function! lsp#omni#default_get_vim_completion_item(item, ...) abort
let l:server_name = get(a:, 1, '')
let l:complete_position = get(a:, 2, lsp#get_position())
let l:complete_position = a:0 >= 2 ? a:2 : lsp#get_position()
let l:word = ''
let l:expandable = v:false