================
@@ -189,6 +189,10 @@ void EmptySubobjectMap::ComputeEmptySubobjectSizes() {
const CXXRecordDecl *BaseDecl = Base.getType()->getAsCXXRecordDecl();
assert(BaseDecl != Class && "Class cannot inherit from itself.");
+ // Skip invalid base declarations to avoid assert in getASTRecordLayout
+ if (BaseDecl->isInvalidDecl())
----------------
vgvassilev wrote:
I think this should go even higher up. ComputeEmptySubobjectSizes And friends
should not be called on invalid declarations.
https://github.com/llvm/llvm-project/pull/208153
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits