[PATCH] D90763: Traverse-ignore explicit template instantiations
Stephen Kelly via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Thu Nov 5 15:11:52 PST 2020
steveire added inline comments.
================
Comment at: clang/lib/ASTMatchers/ASTMatchFinder.cpp:506
+ if (const auto *CTSD = Node.get<ClassTemplateSpecializationDecl>()) {
+ auto SK = CTSD->getSpecializationKind();
+ if (SK == TSK_ExplicitInstantiationDeclaration ||
----------------
aaron.ballman wrote:
> Same here, though this could also be simplified to:
> ```
> ScopedTraversal = (SK == TSK_ExplicitInstantiationDeclaration || SK == TSK_ExplicitInstantiationDefinition);
> ```
If `ScopedTraversal` is set to `true` above, this could wrongly set it to `false`.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D90763/new/
https://reviews.llvm.org/D90763
More information about the cfe-commits
mailing list