================
@@ -126,6 +126,11 @@ bool CXXRecordDecl::forallBases(ForallBasesCallback
BaseMatches) const {
SmallVector<const CXXRecordDecl*, 8> Queue;
const CXXRecordDecl *Record = this;
+
+ if (const CXXRecordDecl *Def = getDefinition())
+ Record = Def;
+ else if (!dataPtr())
+ return false;
----------------
mizvekov wrote:
I don't get why this is still here, if we discussed this and you agreed the
check is unnecessary.
Moreover, `bases()` is one of the CXXRecordDecl properties which is managed
through the `data` pointer, so retrieving the definition is unnecessary.
https://github.com/llvm/llvm-project/pull/199403
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits