diff options
Diffstat (limited to 'clang/lib/CodeGen')
-rw-r--r-- | clang/lib/CodeGen/CGClass.cpp | 6 | ||||
-rw-r--r-- | clang/lib/CodeGen/CodeGenFunction.h | 3 |
2 files changed, 4 insertions, 5 deletions
diff --git a/clang/lib/CodeGen/CGClass.cpp b/clang/lib/CodeGen/CGClass.cpp index 966a93c6520..856cafe748a 100644 --- a/clang/lib/CodeGen/CGClass.cpp +++ b/clang/lib/CodeGen/CGClass.cpp @@ -594,7 +594,7 @@ static llvm::Value *GetVTTParameter(CodeGenFunction &CGF, GlobalDecl GD) { void CodeGenFunction::EmitClassMemberwiseCopy( llvm::Value *Dest, llvm::Value *Src, const CXXRecordDecl *ClassDecl, - const CXXRecordDecl *BaseClassDecl, QualType Ty) { + const CXXRecordDecl *BaseClassDecl) { CXXCtorType CtorType = Ctor_Complete; if (ClassDecl) { @@ -605,7 +605,7 @@ void CodeGenFunction::EmitClassMemberwiseCopy( CtorType = Ctor_Base; } if (BaseClassDecl->hasTrivialCopyConstructor()) { - EmitAggregateCopy(Dest, Src, Ty); + EmitAggregateCopy(Dest, Src, getContext().getTagDeclType(BaseClassDecl)); return; } @@ -718,7 +718,7 @@ CodeGenFunction::SynthesizeCXXCopyConstructor(const FunctionArgList &Args) { } else EmitClassMemberwiseCopy(LHS.getAddress(), RHS.getAddress(), - 0 /*ClassDecl*/, FieldClassDecl, FieldType); + 0 /*ClassDecl*/, FieldClassDecl); continue; } diff --git a/clang/lib/CodeGen/CodeGenFunction.h b/clang/lib/CodeGen/CodeGenFunction.h index c62d19a7abb..0f19c2eae1f 100644 --- a/clang/lib/CodeGen/CodeGenFunction.h +++ b/clang/lib/CodeGen/CodeGenFunction.h @@ -819,8 +819,7 @@ public: void EmitClassMemberwiseCopy(llvm::Value *DestValue, llvm::Value *SrcValue, const CXXRecordDecl *ClassDecl, - const CXXRecordDecl *BaseClassDecl, - QualType Ty); + const CXXRecordDecl *BaseClassDecl); void EmitClassCopyAssignment(llvm::Value *DestValue, llvm::Value *SrcValue, const CXXRecordDecl *ClassDecl); |