================
@@ -811,9 +811,15 @@ void CIRRecordLowering::lowerUnion() {
fieldTypes.push_back(fieldType);
}
- if (!storageType)
- cirGenTypes.getCGModule().errorNYI(recordDecl->getSourceRange(),
- "No-storage Union NYI");
+ if (!storageType) {
+ if (layoutSize.isZero())
----------------
andykaylor wrote:
Both classic codegen and the incubator just call
`appendPaddingBytes(LayoutSize);` here. Why not do that? I believe the AST will
have set the size appropriately to handle the alignment.
https://github.com/llvm/llvm-project/pull/172666
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits