[clangd] Query index in code completion no-compile mode.
authorSam McCall <sam.mccall@gmail.com>
Fri, 26 Apr 2019 07:45:49 +0000 (07:45 +0000)
committerSam McCall <sam.mccall@gmail.com>
Fri, 26 Apr 2019 07:45:49 +0000 (07:45 +0000)
commitc316b22496017c48aba08de1fb69554404bc311b
tree554b5a98878c4fc53f9f99e751e2f4476c2a83f1
parentd538b70b44a1845398bd707dad7bf1e4f356441e
[clangd] Query index in code completion no-compile mode.

Summary: We scrape the enclosing scopes from the source file, and use them in the query.

Reviewers: kadircet

Subscribers: ilya-biryukov, MaskRay, jkorous, mgrang, arphaman, cfe-commits

Tags: #clang

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

llvm-svn: 359284
clang-tools-extra/clangd/CodeComplete.cpp
clang-tools-extra/clangd/SourceCode.cpp
clang-tools-extra/clangd/SourceCode.h
clang-tools-extra/unittests/clangd/CodeCompleteTests.cpp
clang-tools-extra/unittests/clangd/SourceCodeTests.cpp