From 367d1223650cd1b94dc48e886237783692fe6059 Mon Sep 17 00:00:00 2001 From: Eli Friedman Date: Fri, 4 Dec 2009 08:40:51 +0000 Subject: [PATCH] Remove unused argument. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@90563 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/CodeGen/CGVtable.cpp | 30 ++++++++++++++---------------- 1 file changed, 14 insertions(+), 16 deletions(-) diff --git a/lib/CodeGen/CGVtable.cpp b/lib/CodeGen/CGVtable.cpp index 40daadb824..6a03aeab5d 100644 --- a/lib/CodeGen/CGVtable.cpp +++ b/lib/CodeGen/CGVtable.cpp @@ -284,9 +284,9 @@ public: return 0; } - bool OverrideMethod(GlobalDecl GD, llvm::Constant *m, - bool MorallyVirtual, Index_t OverrideOffset, - Index_t Offset, int64_t CurrentVBaseOffset); + bool OverrideMethod(GlobalDecl GD, bool MorallyVirtual, + Index_t OverrideOffset, Index_t Offset, + int64_t CurrentVBaseOffset); /// AppendMethods - Append the current methods to the vtable. void AppendMethodsToVtable(); @@ -315,15 +315,15 @@ public: if (const CXXDestructorDecl *DD = dyn_cast(MD)) { // Override both the complete and the deleting destructor. GlobalDecl CompDtor(DD, Dtor_Complete); - OverrideMethod(CompDtor, WrapAddrOf(CompDtor), MorallyVirtual, - OverrideOffset, Offset, CurrentVBaseOffset); - + OverrideMethod(CompDtor, MorallyVirtual, OverrideOffset, Offset, + CurrentVBaseOffset); + GlobalDecl DeletingDtor(DD, Dtor_Deleting); - OverrideMethod(DeletingDtor, WrapAddrOf(DeletingDtor), MorallyVirtual, - OverrideOffset, Offset, CurrentVBaseOffset); + OverrideMethod(DeletingDtor, MorallyVirtual, OverrideOffset, Offset, + CurrentVBaseOffset); } else { - OverrideMethod(MD, WrapAddrOf(MD), MorallyVirtual, OverrideOffset, - Offset, CurrentVBaseOffset); + OverrideMethod(MD, MorallyVirtual, OverrideOffset, Offset, + CurrentVBaseOffset); } } } @@ -331,10 +331,8 @@ public: void AddMethod(const GlobalDecl GD, bool MorallyVirtual, Index_t Offset, int64_t CurrentVBaseOffset) { - llvm::Constant *m = WrapAddrOf(GD); - // If we can find a previously allocated slot for this, reuse it. - if (OverrideMethod(GD, m, MorallyVirtual, Offset, Offset, + if (OverrideMethod(GD, MorallyVirtual, Offset, Offset, CurrentVBaseOffset)) return; @@ -723,9 +721,9 @@ TypeConversionRequiresAdjustment(ASTContext &Ctx, return TypeConversionRequiresAdjustment(Ctx, DerivedDecl, BaseDecl); } -bool VtableBuilder::OverrideMethod(GlobalDecl GD, llvm::Constant *m, - bool MorallyVirtual, Index_t OverrideOffset, - Index_t Offset, int64_t CurrentVBaseOffset) { +bool VtableBuilder::OverrideMethod(GlobalDecl GD, bool MorallyVirtual, + Index_t OverrideOffset, Index_t Offset, + int64_t CurrentVBaseOffset) { const CXXMethodDecl *MD = cast(GD.getDecl()); const bool isPure = MD->isPure();