ioeric added a comment.
Ok, I am convinced :) Putting the context key into TUScheduler.cpp and exposing
a static method to access it sound like a better idea afterall. Thanks for the
suggestions!
Repository:
rCTE Clang Tools Extra
https://reviews.llvm.org/D50446
ioeric updated this revision to Diff 159746.
ioeric marked 3 inline comments as done.
ioeric added a comment.
Herald added a subscriber: javed.absar.
- Addressed review comments.
Repository:
rCTE Clang Tools Extra
https://reviews.llvm.org/D50446
Files:
clangd/TUScheduler.cpp
ilya-biryukov added inline comments.
Comment at: clangd/ClangdServer.cpp:162
+WithContextValue WithFileName(kActiveFile, File);
// FIXME(ibiryukov): even if Preamble is non-null, we may want to check
ioeric wrote:
> ilya-biryukov wrote:
> > If we want
ioeric added a comment.
In https://reviews.llvm.org/D50446#1192282, @ilya-biryukov wrote:
> Short summary of the offline discussion: I suggest adding this parameter into
> the corresponding requests of the index (FuzzyFindRequest,
> FindDefinitionsRequest) instead of stashing it in the
ilya-biryukov added a comment.
Short summary of the offline discussion: I suggest adding this parameter into
the corresponding requests of the index (FuzzyFindRequest,
FindDefinitionsRequest) instead of stashing it in the context. Context has all
the same problems as the global variables, so
ioeric created this revision.
ioeric added a reviewer: ilya-biryukov.
Herald added subscribers: cfe-commits, arphaman, jkorous, MaskRay.
This allows implementations like different symbol indexes to know what
the current active file is. For example, some customized index implementation
might