From 26584cac81393327ed9492607d4e8b9461da926d Mon Sep 17 00:00:00 2001 From: Rian Neogi Date: Thu, 15 Mar 2018 04:16:47 +0530 Subject: [PATCH] Fix completion on semicolon --- src/messages/text_document_completion.cc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/messages/text_document_completion.cc b/src/messages/text_document_completion.cc index 267223f3..6c5c1571 100644 --- a/src/messages/text_document_completion.cc +++ b/src/messages/text_document_completion.cc @@ -354,8 +354,8 @@ struct TextDocumentCompletionHandler : MessageHandler { // results Only do this when trigger is not manual or context doesn't // exist (for Atom support). if (existing_completion.empty() && is_global_completion && - (request->params.context && request->params.context->triggerKind != - lsCompletionTriggerKind::Invoked)) { + (!request->params.context || request->params.context->triggerKind == + lsCompletionTriggerKind::TriggerCharacter)) { LOG_S(INFO) << "Existing completion is empty, no completion results " "will be returned"; Out_TextDocumentComplete out;