[clang-tools-extra] [clang-tidy] Create bugprone-public-enable-shared-from-this check (PR #102299)
via cfe-commits
cfe-commits at lists.llvm.org
Sun Aug 11 18:26:18 PDT 2024
MichelleCDjunaidi wrote:
> Actually an ASTVisitor approach could be better here, this way you could create a set of all the `CXXRecordDecls` that publicly inherit from or transitively inherit from `::std::enable_shared_from_this` during traversal
To confirm, @njames93 do you mean clang::RecursiveASTVisitor? What I'm getting from this conversation is maintaining the name of the matched classes in a vector and checking for every other class if it inherits from `::std::enable_shared_from_this` or classes in the vector.
https://github.com/llvm/llvm-project/pull/102299
More information about the cfe-commits
mailing list