[PATCH] D47183: [clangd] Support multiple sema code completion callbacks.
Eric Liu via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Tue May 22 01:24:10 PDT 2018
ioeric created this revision.
ioeric added reviewers: ilya-biryukov, sammccall.
Herald added subscribers: cfe-commits, jkorous, MaskRay, klimek.
Currently, we only handle the first callback from sema code completion
and ignore results from potential following callbacks. This causes
causes loss of completion results when multiple contexts are tried by Sema.
For example, we wouldn't get any completion result in the following completion
as the first attemped context is natural language which has no
candidate. The parser would backtrack and tried a completion with AST
semantic, which would find candidate "::x".
void f(const char*, int);
int x;
void main() {
F(::^);
}
Repository:
rCTE Clang Tools Extra
https://reviews.llvm.org/D47183
Files:
clangd/CodeComplete.cpp
unittests/clangd/CodeCompleteTests.cpp
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D47183.147957.patch
Type: text/x-patch
Size: 4775 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20180522/3ace5d9b/attachment.bin>
More information about the cfe-commits
mailing list