[PATCH] D52357: [clangd] Force Dex to respect symbol collector flags

Eric Liu via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Fri Sep 21 07:34:27 PDT 2018


ioeric accepted this revision.
ioeric added inline comments.
This revision is now accepted and ready to land.


================
Comment at: clang-tools-extra/clangd/index/dex/Dex.cpp:184
 
+  // Filter symbols which are not indexed for code completion.
+  if (Req.RestrictForCodeCompletion)
----------------
nit: the comment seems trivial from the if-condition. Maybe remove?


================
Comment at: clang-tools-extra/unittests/clangd/DexTests.cpp:594
+  EXPECT_THAT(match(I, Req), ElementsAre("Completion", "NoCompletion"));
+  CodeCompletionSymbol.Flags = Symbol::SymbolFlag::IndexedForCodeCompletion;
+  NonCodeCompletionSymbol.Flags = Symbol::SymbolFlag::None;
----------------
I think the symbol flags should be set before both requests.


https://reviews.llvm.org/D52357





More information about the cfe-commits mailing list