summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--autoload/ale/completion.vim5
-rw-r--r--test/completion/test_lsp_completion_messages.vader4
2 files changed, 3 insertions, 6 deletions
diff --git a/autoload/ale/completion.vim b/autoload/ale/completion.vim
index 9158f227..ee156056 100644
--- a/autoload/ale/completion.vim
+++ b/autoload/ale/completion.vim
@@ -521,10 +521,7 @@ function! s:OnReady(linter, lsp_details) abort
let l:message = ale#lsp#message#Completion(
\ l:buffer,
\ b:ale_completion_info.line,
- \ min([
- \ b:ale_completion_info.line_length,
- \ b:ale_completion_info.column,
- \ ]) + 1,
+ \ b:ale_completion_info.column,
\ ale#completion#GetTriggerCharacter(&filetype, b:ale_completion_info.prefix),
\)
endif
diff --git a/test/completion/test_lsp_completion_messages.vader b/test/completion/test_lsp_completion_messages.vader
index 9598e5f0..6bd241a8 100644
--- a/test/completion/test_lsp_completion_messages.vader
+++ b/test/completion/test_lsp_completion_messages.vader
@@ -219,7 +219,7 @@ Execute(The right message should be sent for the initial LSP request):
\ }],
\ [0, 'textDocument/completion', {
\ 'textDocument': {'uri': ale#path#ToURI(expand('%:p'))},
- \ 'position': {'line': 0, 'character': 3},
+ \ 'position': {'line': 0, 'character': 2},
\ }],
\ ],
\ g:message_list
@@ -280,7 +280,7 @@ Execute(Two completion requests shouldn't be sent in a row):
\ }],
\ [0, 'textDocument/completion', {
\ 'textDocument': {'uri': ale#path#ToURI(expand('%:p'))},
- \ 'position': {'line': 0, 'character': 3},
+ \ 'position': {'line': 0, 'character': 2},
\ }],
\ ],
\ g:message_list