We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent d9ed270 commit c2d3f39Copy full SHA for c2d3f39
clang/lib/AST/RecordLayoutBuilder.cpp
@@ -3262,9 +3262,9 @@ void MicrosoftRecordLayoutBuilder::finalizeLayout(const RecordDecl *RD) {
3262
return;
3263
}
3264
unsigned CharBitNum = Context.getTargetInfo().getCharWidth();
3265
- uint64_t SizeInBits = Context.toBits(Size);
3266
- if (SizeInBits > UnpaddedSizeInBits) {
3267
- unsigned int PadSize = SizeInBits - UnpaddedSizeInBits;
+ uint64_t DataSizeInBits = Context.toBits(DataSize);
+ if (DataSizeInBits > UnpaddedSizeInBits) {
+ unsigned int PadSize = DataSizeInBits - UnpaddedSizeInBits;
3268
bool InBits = true;
3269
if (PadSize % CharBitNum == 0) {
3270
PadSize = PadSize / CharBitNum;
0 commit comments