This revision was automatically updated to reflect the committed changes.
Closed by commit rL322929: [clangd] Collect enum constants in SymbolCollector
(authored by hokein, committed by ).
Herald added a subscriber: llvm-commits.
Repository:
rL LLVM
https://reviews.llvm.org/D42074
Files:
cl
hokein updated this revision to Diff 130568.
hokein marked an inline comment as done.
hokein added a comment.
Update comment.
Repository:
rCTE Clang Tools Extra
https://reviews.llvm.org/D42074
Files:
clangd/index/SymbolCollector.cpp
unittests/clangd/SymbolCollectorTests.cpp
Index: unit
ilya-biryukov accepted this revision.
ilya-biryukov added a comment.
This revision is now accepted and ready to land.
LGTM. (See the comment about changing the comment, though)
Comment at: clangd/index/SymbolCollector.cpp:75
+ // Skip nameless declarations.
+ if (ND->getDeclN
hokein updated this revision to Diff 130395.
hokein marked an inline comment as done.
hokein added a comment.
Add one more test.
Repository:
rCTE Clang Tools Extra
https://reviews.llvm.org/D42074
Files:
clangd/index/SymbolCollector.cpp
unittests/clangd/SymbolCollectorTests.cpp
Index: u
ioeric added inline comments.
Comment at: unittests/clangd/SymbolCollectorTests.cpp:164
+TEST_F(SymbolCollectorTest, IncludeEnums) {
+ CollectorOpts.IndexMainFiles = false;
Could you add a test case like the following and check whether `ns::X` is in
the resul
hokein added inline comments.
Comment at: clangd/index/SymbolCollector.cpp:75
+ // Skip nameless declarations.
+ if (ND->getDeclName().isEmpty())
+return true;
ilya-biryukov wrote:
> What are those declarations exactly?
This would ignore anonymous declarat
hokein updated this revision to Diff 130372.
hokein marked 2 inline comments as done.
hokein added a comment.
Herald added a reviewer: jkorous-apple.
Ignore enum constants in scoped enum.
Repository:
rCTE Clang Tools Extra
https://reviews.llvm.org/D42074
Files:
clangd/index/SymbolCollector
ilya-biryukov added inline comments.
Comment at: clangd/index/SymbolCollector.cpp:75
+ // Skip nameless declarations.
+ if (ND->getDeclName().isEmpty())
+return true;
What are those declarations exactly?
Comment at: unittests/clangd/Symbo
hokein created this revision.
hokein added a reviewer: ilya-biryukov.
Herald added a subscriber: klimek.
- ignore nameless symbols
- include enum constant declarataion
Repository:
rCTE Clang Tools Extra
https://reviews.llvm.org/D42074
Files:
clangd/index/SymbolCollector.cpp
unittests/cla