hokein accepted this revision.
hokein added a comment.
This revision is now accepted and ready to land.

LGTM



================
Comment at: clangd/index/SymbolCollector.h:20
 
-// Collect all symbols from an AST.
-//
-// Clients (e.g. clangd) can use SymbolCollector together with
-// index::indexTopLevelDecls to retrieve all symbols when the source file is
-// changed.
+/// \brief Collect all symbols from an AST.
+///
----------------
We should also document what kinds of symbols we are collecting, since this 
patch has changed the behavior (only collect top-level symbols).


================
Comment at: unittests/clangd/SymbolCollectorTests.cpp:165
+TEST_F(SymbolCollectorTest, IgnoreSymbolsInMainFile) {
+  const std::string Header = R"(
+    class Foo {};
----------------
nit: although the default value is false, I'd explicitly specify 
`CollectorOpts.IndexMainFiles = false;` (readers don't need to jump to another 
file to see the default value).


Repository:
  rCTE Clang Tools Extra

https://reviews.llvm.org/D41823



_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to