diff options
author | John McCall <rjmccall@apple.com> | 2011-03-11 20:59:21 +0000 |
---|---|---|
committer | John McCall <rjmccall@apple.com> | 2011-03-11 20:59:21 +0000 |
commit | 413ebdb1af6fb0d81845b61254daf02ba0449afd (patch) | |
tree | 519acbf01d04c6673825029eaead650e39c512fc /lib/CodeGen/CGExprCXX.cpp | |
parent | f4f7cb814f8537606754b9eb8848094196e73214 (diff) |
Use a slightly more semantic interface for emitting call arguments.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@127494 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/CGExprCXX.cpp')
-rw-r--r-- | lib/CodeGen/CGExprCXX.cpp | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/lib/CodeGen/CGExprCXX.cpp b/lib/CodeGen/CGExprCXX.cpp index d0d0f4eb1f..0ca024059c 100644 --- a/lib/CodeGen/CGExprCXX.cpp +++ b/lib/CodeGen/CGExprCXX.cpp @@ -956,9 +956,7 @@ llvm::Value *CodeGenFunction::EmitCXXNewExpr(const CXXNewExpr *E) { placementArg->getType()) && "type mismatch in call argument!"); - allocatorArgs.push_back(std::make_pair(EmitCallArg(*placementArg, argType), - argType)); - + EmitCallArg(allocatorArgs, *placementArg, argType); } // Either we've emitted all the call args, or we have a call to a @@ -970,9 +968,7 @@ llvm::Value *CodeGenFunction::EmitCXXNewExpr(const CXXNewExpr *E) { // If we still have any arguments, emit them using the type of the argument. for (CXXNewExpr::const_arg_iterator placementArgsEnd = E->placement_arg_end(); placementArg != placementArgsEnd; ++placementArg) { - QualType argType = placementArg->getType(); - allocatorArgs.push_back(std::make_pair(EmitCallArg(*placementArg, argType), - argType)); + EmitCallArg(allocatorArgs, *placementArg, placementArg->getType()); } // Emit the allocation call. |