[clangd] Add ':' to completion trigger characters.

Summary:
Without it we don't get completion requests from VSCode after
nested name qualifiers (e.g. after 'std::').

Reviewers: krasimir, bkramer

Reviewed By: krasimir

Subscribers: klimek, cfe-commits

Differential Revision: https://reviews.llvm.org/D35986

llvm-svn: 309550
This commit is contained in:
Ilya Biryukov 2017-07-31 09:27:52 +00:00
parent e36d7a6d68
commit a2e7ca99e0
2 changed files with 3 additions and 3 deletions

View File

@ -86,7 +86,7 @@ void ClangdLSPServer::LSPProtocolCallbacks::onInitialize(StringRef ID,
"documentRangeFormattingProvider": true,
"documentOnTypeFormattingProvider": {"firstTriggerCharacter":"}","moreTriggerCharacter":[]},
"codeActionProvider": true,
"completionProvider": {"resolveProvider": false, "triggerCharacters": [".",">"]},
"completionProvider": {"resolveProvider": false, "triggerCharacters": [".",">",":"]},
"definitionProvider": true
}}})");
}

View File

@ -4,14 +4,14 @@
Content-Length: 125
{"jsonrpc":"2.0","id":0,"method":"initialize","params":{"processId":123,"rootPath":"clangd","capabilities":{},"trace":"off"}}
# CHECK: Content-Length: 462
# CHECK: Content-Length: 466
# CHECK: {"jsonrpc":"2.0","id":0,"result":{"capabilities":{
# CHECK: "textDocumentSync": 1,
# CHECK: "documentFormattingProvider": true,
# CHECK: "documentRangeFormattingProvider": true,
# CHECK: "documentOnTypeFormattingProvider": {"firstTriggerCharacter":"}","moreTriggerCharacter":[]},
# CHECK: "codeActionProvider": true,
# CHECK: "completionProvider": {"resolveProvider": false, "triggerCharacters": [".",">"]},
# CHECK: "completionProvider": {"resolveProvider": false, "triggerCharacters": [".",">",":"]},
# CHECK: "definitionProvider": true
# CHECK: }}}
#