[PATCH] D71199: [clang-tidy] New check cppcoreguidelines-prefer-member-initializer
Balogh, Ádám via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Thu Sep 10 09:06:09 PDT 2020
baloghadamsoftware added a comment.
I found the problem: `hasBody()` always returns true if the function has //somewhere// a body. This means that also the `hasBody` matcher matches forward declarations. However, I only need the definition. This far I could not find any method to achieve that: `isDefinition()` also returns true for forward declarations, as well as comparing with the `CanonicalDecl`. I am looking further...
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D71199/new/
https://reviews.llvm.org/D71199
More information about the cfe-commits
mailing list