[clang] [CIR] Fix record layout for [[no_unique_address]] fields (PR #186701)

Henrich Lauko via cfe-commits cfe-commits at lists.llvm.org
Thu Apr 2 08:34:56 PDT 2026


================
@@ -572,9 +572,15 @@ void CIRRecordLowering::accumulateFields() {
       assert((field == fieldEnd || !field->isBitField()) &&
              "Failed to accumulate all the bitfields");
     } else if (!field->isZeroSize(astContext)) {
----------------
xlauko wrote:

That condition was there originally written by you, replacing it by `isEmptyFieldForLayout` breaks some tests, I will investigate further.

https://github.com/llvm/llvm-project/pull/186701


More information about the cfe-commits mailing list