[PATCH] D69241: [clangd] Handle the missing constructor initializers in findExplicitReferences.
Haojian Wu via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Tue Oct 22 06:19:43 PDT 2019
hokein marked an inline comment as done.
hokein added inline comments.
================
Comment at: clang-tools-extra/clangd/FindTarget.cpp:677
if (const CXXCtorInitializer *CCI = N.get<CXXCtorInitializer>()) {
- if (CCI->isBaseInitializer())
- return refInTypeLoc(CCI->getBaseClassLoc());
- assert(CCI->isAnyMemberInitializer());
- return {ReferenceLoc{NestedNameSpecifierLoc(),
- CCI->getMemberLocation(),
- /*IsDecl=*/false,
- {CCI->getAnyMember()}}};
+ // Other type initializers (e.g. base initializer) are handled by visiting
+ // the typeLoc.
----------------
ilya-biryukov wrote:
> I believe base initializers are the only ones left, but the comment suggests there are more cases. Maybe change to:
> ```
> // Base initializers are handled by visting the type loc.
> ```
> Or am I missing something?
>
there are others, delegating initializers.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D69241/new/
https://reviews.llvm.org/D69241
More information about the cfe-commits
mailing list