r197083 - [ms-abi][cleanup] Removing FinalizeCXXLayout : no functional change
Warren Hunt
whunt at google.com
Wed Dec 11 14:28:32 PST 2013
Author: whunt
Date: Wed Dec 11 16:28:32 2013
New Revision: 197083
URL: http://llvm.org/viewvc/llvm-project?rev=197083&view=rev
Log:
[ms-abi][cleanup] Removing FinalizeCXXLayout : no functional change
After r196549 there is no need to separate FinalizeCXXLayout and
FinalizeLayout so they were merged and FinalizeCXXLayout was eliminated.
Modified:
cfe/trunk/lib/AST/RecordLayoutBuilder.cpp
Modified: cfe/trunk/lib/AST/RecordLayoutBuilder.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/AST/RecordLayoutBuilder.cpp?rev=197083&r1=197082&r2=197083&view=diff
==============================================================================
--- cfe/trunk/lib/AST/RecordLayoutBuilder.cpp (original)
+++ cfe/trunk/lib/AST/RecordLayoutBuilder.cpp Wed Dec 11 16:28:32 2013
@@ -2063,9 +2063,6 @@ public:
void fixSizeAndAlignment(const RecordDecl *FD);
void layoutVirtualBases(const CXXRecordDecl *RD);
void layoutVirtualBase(const CXXRecordDecl *RD, bool HasVtordisp);
- /// \brief Flushes the lazy virtual base and conditionally rounds up to
- /// alignment.
- void finalizeCXXLayout(const CXXRecordDecl *RD);
void finalizeLayout(const RecordDecl *RD);
/// \brief Updates the alignment of the type. This function doesn't take any
@@ -2245,7 +2242,6 @@ void MicrosoftRecordLayoutBuilder::cxxLa
layoutFields(RD);
fixSizeAndAlignment(RD);
layoutVirtualBases(RD);
- finalizeCXXLayout(RD);
finalizeLayout(RD);
}
@@ -2613,18 +2609,13 @@ void MicrosoftRecordLayoutBuilder::layou
PreviousBaseLayout = &Layout;
}
-void MicrosoftRecordLayoutBuilder::finalizeCXXLayout(const CXXRecordDecl *RD) {
- if (RD->vbases_begin() == RD->vbases_end() || !RequiredAlignment.isZero())
- Size = Size.RoundUpToAlignment(Alignment);
-
+void MicrosoftRecordLayoutBuilder::finalizeLayout(const RecordDecl *RD) {
if (Size.isZero()) {
HasZeroSizedSubObject = true;
LeadsWithZeroSizedBase = true;
Size = Alignment;
}
-}
-void MicrosoftRecordLayoutBuilder::finalizeLayout(const RecordDecl *RD) {
if (!RequiredAlignment.isZero()) {
updateAlignment(RequiredAlignment);
Size = Size.RoundUpToAlignment(Alignment);
More information about the cfe-commits
mailing list