From: Alexey Samsonov Date: Tue, 26 Aug 2014 20:18:26 +0000 (+0000) Subject: Fix an incorrect assert condition added in r216410. X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=73945fa57a8c9ae296c7bbd4a91348fd6c0ad07f;p=clang Fix an incorrect assert condition added in r216410. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@216479 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/lib/CodeGen/CGClass.cpp b/lib/CodeGen/CGClass.cpp index 9c1f548c83..6f7dfefa95 100644 --- a/lib/CodeGen/CGClass.cpp +++ b/lib/CodeGen/CGClass.cpp @@ -1692,7 +1692,7 @@ CodeGenFunction::EmitSynthesizedCXXCopyCtorCall(const CXXConstructorDecl *D, llvm::Value *This, llvm::Value *Src, const CXXConstructExpr *E) { if (D->isTrivial()) { - assert(E->getNumArgs() && "unexpected argcount for trivial ctor"); + assert(E->getNumArgs() == 1 && "unexpected argcount for trivial ctor"); assert(D->isCopyOrMoveConstructor() && "trivial 1-arg ctor not a copy/move ctor"); EmitAggregateCopy(This, Src, E->arg_begin()->getType());