diff options
Diffstat (limited to 'lib/CodeGen/CGVtable.cpp')
-rw-r--r-- | lib/CodeGen/CGVtable.cpp | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/lib/CodeGen/CGVtable.cpp b/lib/CodeGen/CGVtable.cpp index 93153e31b6..16c38002bc 100644 --- a/lib/CodeGen/CGVtable.cpp +++ b/lib/CodeGen/CGVtable.cpp @@ -1924,8 +1924,6 @@ void CGVtableInfo::ComputeMethodVtableIndices(const CXXRecordDecl *RD) { if (!MD->isVirtual()) continue; - bool ShouldAddEntryForMethod = true; - // Check if this method overrides a method in the primary base. if (const CXXMethodDecl *OverriddenMD = OverridesMethodInPrimaryBase(MD, PrimaryBases)) { @@ -1948,14 +1946,10 @@ void CGVtableInfo::ComputeMethodVtableIndices(const CXXRecordDecl *RD) { } // We don't need to add an entry for this method. - ShouldAddEntryForMethod = false; - break; + continue; } } - if (!ShouldAddEntryForMethod) - continue; - if (const CXXDestructorDecl *DD = dyn_cast<CXXDestructorDecl>(MD)) { if (MD->isImplicit()) { assert(!ImplicitVirtualDtor && |