Convert one last size variable to CharUnits (follow-on to 94577).

llvm-svn: 94579
This commit is contained in:
Ken Dyck 2010-01-26 19:59:28 +00:00
parent 6b0888a07d
commit 7df3cbeb01
1 changed files with 3 additions and 2 deletions

View File

@ -656,8 +656,9 @@ void CodeGenFunction::EmitDeleteCall(const FunctionDecl *DeleteFD,
QualType SizeTy;
if (DeleteFTy->getNumArgs() == 2) {
SizeTy = DeleteFTy->getArgType(1);
uint64_t DeleteTypeSize = getContext().getTypeSize(DeleteTy) / 8;
Size = llvm::ConstantInt::get(ConvertType(SizeTy), DeleteTypeSize);
CharUnits DeleteTypeSize = getContext().getTypeSizeInChars(DeleteTy);
Size = llvm::ConstantInt::get(ConvertType(SizeTy),
DeleteTypeSize.getQuantity());
}
if (DeleteFD->getOverloadedOperator() == OO_Array_Delete &&