[PATCH] D54202: [clangd] Drop namespace references in the index.

Kadir Cetinkaya via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Wed Nov 7 05:08:05 PST 2018


kadircet added inline comments.


================
Comment at: clangd/index/SymbolCollector.cpp:359
     return true;
-  if (CollectRef &&
+  if (CollectRef && !isa<NamespaceDecl>(ND) &&
       (Opts.RefsInHeaders || SM.getFileID(SpellingLoc) == SM.getMainFileID()))
----------------
Why not handle in `shouldCollectSymbol` ?


================
Comment at: clangd/index/SymbolCollector.h:60
+    /// Note that references of namespace decls are not collected, as they
+    /// contribute large part of the index, anbd they are less useful compared
+    /// with other decls.
----------------
another typo anbd -> and


Repository:
  rCTE Clang Tools Extra

https://reviews.llvm.org/D54202





More information about the cfe-commits mailing list