njames93 wrote: > > How are classes that derive other classes that implement > > `enable_shared_from_this` > > > > ```c++ > > class A : public std::enable_shared_from_this {}; > > class B : private A{}; > > ``` > > Looking at the AST dump that clang-check gives, it seems that B doesn't have > any knowledge of A's internals, so the current approach will not work. > Correct me if I'm wrong though
I think you'd have to recursively check the inheritance of a class and if you have any private that derives from `std::enable_shared_from_this` https://github.com/llvm/llvm-project/pull/102299 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits