Move ConstantExpr to 2.5 API.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@77494 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Owen Anderson
2009-07-29 18:55:55 +00:00
parent 26ef510d5d
commit baf3c40440
43 changed files with 553 additions and 744 deletions

View File

@@ -44,9 +44,9 @@ static Value *isBytewiseValue(Value *V, LLVMContext& Context) {
// corresponding integer value is "byteable". An important case is 0.0.
if (ConstantFP *CFP = dyn_cast<ConstantFP>(V)) {
if (CFP->getType() == Type::FloatTy)
V = Context.getConstantExprBitCast(CFP, Type::Int32Ty);
V = ConstantExpr::getBitCast(CFP, Type::Int32Ty);
if (CFP->getType() == Type::DoubleTy)
V = Context.getConstantExprBitCast(CFP, Type::Int64Ty);
V = ConstantExpr::getBitCast(CFP, Type::Int64Ty);
// Don't handle long double formats, which have strange constraints.
}