This revision was landed with ongoing or failed builds.
This revision was automatically updated to reflect the committed changes.
Closed by commit rGf443793d26c3: [clangd] Ensure Ref::Container refers to an
indexed symbol (authored by nridge).
Repository:
rG LLVM Github Monorepo
CHANGES SINCE
nridge updated this revision to Diff 360714.
nridge marked 3 inline comments as done.
nridge added a comment.
Address review comments
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D105083/new/
https://reviews.llvm.org/D105083
Files:
clang-tools-e
kadircet accepted this revision.
kadircet added a comment.
This revision is now accepted and ready to land.
thanks, lgtm!
sorry for the late reply :( adding a couple nits.
Comment at: clang-tools-extra/clangd/index/SymbolCollector.cpp:170
+ while (Enclosing) {
+const Named
nridge marked an inline comment as done.
nridge added inline comments.
Comment at: clang-tools-extra/clangd/index/SymbolCollector.cpp:159
+// indexed, we walk further up because Ref::Container should always be
+// an indexed symbol.
+const Decl *getRefContainer(const Decl *Enclos
nridge updated this revision to Diff 357823.
nridge added a comment.
Address review comments
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D105083/new/
https://reviews.llvm.org/D105083
Files:
clang-tools-extra/clangd/index/SymbolCollector.cpp
c
nridge added inline comments.
Comment at: clang-tools-extra/clangd/index/SymbolCollector.cpp:489
DeclRefs[ND].push_back(
-SymbolRef{SM.getFileLoc(Loc), Roles, ASTNode.Parent});
+SymbolRef{SM.getFileLoc(Loc), Roles, getRefContainer(ASTNode.Parent)});
// Don
kadircet added inline comments.
Comment at: clang-tools-extra/clangd/index/SymbolCollector.cpp:159
+// indexed, we walk further up because Ref::Container should always be
+// an indexed symbol.
+const Decl *getRefContainer(const Decl *Enclosing,
can you also add
nridge updated this revision to Diff 356428.
nridge marked an inline comment as done.
nridge added a comment.
Addressed review comments, except for the one about using ContainerDC, for the
reason explained
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.o
nridge added inline comments.
Comment at: clang-tools-extra/clangd/index/SymbolCollector.cpp:489
DeclRefs[ND].push_back(
-SymbolRef{SM.getFileLoc(Loc), Roles, ASTNode.Parent});
+SymbolRef{SM.getFileLoc(Loc), Roles, getRefContainer(ASTNode.Parent)});
// Don
kadircet added inline comments.
Comment at: clang-tools-extra/clangd/index/SymbolCollector.cpp:334
+const Decl *SymbolCollector::getRefContainer(const Decl *Enclosing) {
+ const NamedDecl *ND = dyn_cast_or_null(Enclosing);
why do we need to expose this functio
nridge created this revision.
nridge added a reviewer: kadircet.
Herald added subscribers: usaxena95, arphaman.
nridge requested review of this revision.
Herald added subscribers: cfe-commits, MaskRay, ilya-biryukov.
Herald added a project: clang-tools-extra.
Fixes https://github.com/clangd/clangd
11 matches
Mail list logo