diff options
author | Eli Friedman <eli.friedman@gmail.com> | 2011-12-03 02:13:40 +0000 |
---|---|---|
committer | Eli Friedman <eli.friedman@gmail.com> | 2011-12-03 02:13:40 +0000 |
commit | d7722d9d76a851e7897f4127626616d3b1b8e530 (patch) | |
tree | 3e4250946873fe487487e1ae1695267b156bf736 /lib/CodeGen/CGExprCXX.cpp | |
parent | c5e0f9b44782204437de21594c1748b1405d90bc (diff) |
Switch the Alignment argument on AggValueSlot over to CharUnits, per John's review comment.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145741 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/CGExprCXX.cpp')
-rw-r--r-- | lib/CodeGen/CGExprCXX.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/CodeGen/CGExprCXX.cpp b/lib/CodeGen/CGExprCXX.cpp index e3afda62d4..da1ca2ccf3 100644 --- a/lib/CodeGen/CGExprCXX.cpp +++ b/lib/CodeGen/CGExprCXX.cpp @@ -750,10 +750,10 @@ static void StoreAnyExprIntoOneUnit(CodeGenFunction &CGF, const CXXNewExpr *E, const Expr *Init = E->getConstructorArg(0); QualType AllocType = E->getAllocatedType(); - unsigned Alignment = - CGF.getContext().getTypeAlignInChars(AllocType).getQuantity(); + CharUnits Alignment = CGF.getContext().getTypeAlignInChars(AllocType); if (!CGF.hasAggregateLLVMType(AllocType)) - CGF.EmitScalarInit(Init, 0, CGF.MakeAddrLValue(NewPtr, AllocType, Alignment), + CGF.EmitScalarInit(Init, 0, CGF.MakeAddrLValue(NewPtr, AllocType, + Alignment.getQuantity()), false); else if (AllocType->isAnyComplexType()) CGF.EmitComplexExprIntoAddr(Init, NewPtr, |