rsmith added a comment. In https://reviews.llvm.org/D45174#1054936, @rnk wrote:
> I've convinced myself that this is NFC for MS record layout because this is > the only place we use RD->isEmpty() that matters: > > if (!FoundBase) { > if (MDCUsesEBO && BaseDecl->isEmpty() && > BaseLayout.getNonVirtualSize() == CharUnits::Zero()) { > BaseOffset = CharUnits::Zero(); > } else { > // Otherwise, lay the base out at the end of the MDC. > BaseOffset = Size = Size.alignTo(Info.Alignment); > } > } > > > In particular, that `getNonVirtualSize()` check returns false when unnamed > bitfields get involved. I wonder if we can delete the `getNonVirtualSize()` check now -- I don't see any way that an empty class can have a nonzero nvsize except by this nonempty anonymous bit-fields situation. Repository: rC Clang https://reviews.llvm.org/D45174 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits