================ @@ -368,8 +368,8 @@ bool CXXRecordDecl::FindBaseClass(const CXXBaseSpecifier *Specifier, const CXXRecordDecl *BaseRecord) { assert(BaseRecord->getCanonicalDecl() == BaseRecord && "User data for FindBaseClass is not canonical!"); - return Specifier->getType()->castAs<RecordType>()->getDecl() - ->getCanonicalDecl() == BaseRecord; + return cast<CXXRecordDecl>(Specifier->getType()->getAsRecordDecl()) ---------------- erichkeane wrote:
why this instead of: `Specifier->getType()->getAsCXXRecordDecl()` ?? Same question throughout this patch. https://github.com/llvm/llvm-project/pull/119024 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits