[PATCH] D60126: [clangd] Use identifiers in file as completion candidates when build is not ready.

2019-04-11 Thread Eric Liu via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rCTE358159: [clangd] Use identifiers in file as completion candidates when build is not… (authored by ioeric, committed by ). Changed prior to commit: https://reviews.llvm.org/D60126?vs=194652=194653#toc

[PATCH] D60126: [clangd] Use identifiers in file as completion candidates when build is not ready.

2019-04-11 Thread Eric Liu via Phabricator via cfe-commits
ioeric updated this revision to Diff 194652. ioeric marked 2 inline comments as done. ioeric added a comment. - address comments Repository: rCTE Clang Tools Extra CHANGES SINCE LAST ACTION https://reviews.llvm.org/D60126/new/ https://reviews.llvm.org/D60126 Files:

[PATCH] D60126: [clangd] Use identifiers in file as completion candidates when build is not ready.

2019-04-11 Thread Sam McCall via Phabricator via cfe-commits
sammccall accepted this revision. sammccall added inline comments. This revision is now accepted and ready to land. Comment at: clangd/CodeComplete.cpp:345 + Completion.Origin |= SymbolOrigin::Identifier; + Completion.Name = C.IdentifierResult->Name; +}

[PATCH] D60126: [clangd] Use identifiers in file as completion candidates when build is not ready.

2019-04-11 Thread Eric Liu via Phabricator via cfe-commits
ioeric added inline comments. Comment at: clangd/CodeComplete.cpp:1360 getQueryScopes(Recorder->CCContext, *Recorder->CCSema, Opts); if (!QueryScopes.empty()) ScopeProximity.emplace(QueryScopes); sammccall wrote: > add this to the non-sema

[PATCH] D60126: [clangd] Use identifiers in file as completion candidates when build is not ready.

2019-04-11 Thread Eric Liu via Phabricator via cfe-commits
ioeric updated this revision to Diff 194647. ioeric marked 14 inline comments as done. ioeric added a comment. - address review comments Repository: rCTE Clang Tools Extra CHANGES SINCE LAST ACTION https://reviews.llvm.org/D60126/new/ https://reviews.llvm.org/D60126 Files:

[PATCH] D60126: [clangd] Use identifiers in file as completion candidates when build is not ready.

2019-04-10 Thread Sam McCall via Phabricator via cfe-commits
sammccall added a comment. Very nice! D60503 will conflict, feel free to stall that until this is landed. On the other hand it will simplify some things, e.g. the prefix is already calculated, and typed scope is available if you want that (no enclosing

[PATCH] D60126: [clangd] Use identifiers in file as completion candidates when build is not ready.

2019-04-09 Thread Eric Liu via Phabricator via cfe-commits
ioeric added a comment. Thanks for the review! Comment at: clangd/CodeComplete.cpp:1320 +llvm::IntrusiveRefCntPtr VFS) && { +auto CompletionFilter = speculateCompletionFilter(Content, Pos); +if (!CompletionFilter) { sammccall wrote:

[PATCH] D60126: [clangd] Use identifiers in file as completion candidates when build is not ready.

2019-04-09 Thread Eric Liu via Phabricator via cfe-commits
ioeric updated this revision to Diff 194315. ioeric added a comment. - minor cleanup Repository: rCTE Clang Tools Extra CHANGES SINCE LAST ACTION https://reviews.llvm.org/D60126/new/ https://reviews.llvm.org/D60126 Files: clangd/ClangdServer.cpp clangd/ClangdUnit.cpp

[PATCH] D60126: [clangd] Use identifiers in file as completion candidates when build is not ready.

2019-04-09 Thread Eric Liu via Phabricator via cfe-commits
ioeric updated this revision to Diff 194311. ioeric marked 9 inline comments as done. ioeric added a comment. - address review comments Repository: rCTE Clang Tools Extra CHANGES SINCE LAST ACTION https://reviews.llvm.org/D60126/new/ https://reviews.llvm.org/D60126 Files:

[PATCH] D60126: [clangd] Use identifiers in file as completion candidates when build is not ready.

2019-04-04 Thread Sam McCall via Phabricator via cfe-commits
sammccall added inline comments. Comment at: clangd/CodeComplete.cpp:1136 +std::unique_ptr +indexIdentifiers(llvm::StringRef FileName, llvm::StringRef Content, + const format::FormatStyle ) { as discussed offline, I love the lexer approach but

[PATCH] D60126: [clangd] Use identifiers in file as completion candidates when build is not ready.

2019-04-02 Thread Eric Liu via Phabricator via cfe-commits
ioeric created this revision. ioeric added a reviewer: sammccall. Herald added subscribers: cfe-commits, jdoerfert, kadircet, arphaman, jkorous, MaskRay, ilya-biryukov. Herald added a project: clang. o Lex the code to get the identifiers and put them into a "symbol" index. o Adds a new