diff options
author | Jeffrey Yasskin <jyasskin@google.com> | 2011-07-18 21:45:40 +0000 |
---|---|---|
committer | Jeffrey Yasskin <jyasskin@google.com> | 2011-07-18 21:45:40 +0000 |
commit | 3ba292dbc2acee2d1052fb7ffe332e2164147b47 (patch) | |
tree | 82c6c0d2c93837ac6383546b881dbcd10135f9cf /lib/VMCore/ConstantFold.cpp | |
parent | 3a594f487628b4855d6394c99d5373891a46c797 (diff) |
Add APInt(numBits, ArrayRef<uint64_t> bigVal) constructor to prevent future ambiguity
errors like the one corrected by r135261. Migrate all LLVM callers of the old
constructor to the new one.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@135431 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/VMCore/ConstantFold.cpp')
-rw-r--r-- | lib/VMCore/ConstantFold.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/VMCore/ConstantFold.cpp b/lib/VMCore/ConstantFold.cpp index 85badc8b29..a2f4f621c9 100644 --- a/lib/VMCore/ConstantFold.cpp +++ b/lib/VMCore/ConstantFold.cpp @@ -590,7 +590,7 @@ Constant *llvm::ConstantFoldCastInstruction(unsigned opc, Constant *V, uint32_t DestBitWidth = cast<IntegerType>(DestTy)->getBitWidth(); (void) V.convertToInteger(x, DestBitWidth, opc==Instruction::FPToSI, APFloat::rmTowardZero, &ignored); - APInt Val(DestBitWidth, 2, x); + APInt Val(DestBitWidth, x); return ConstantInt::get(FPC->getContext(), Val); } return 0; // Can't fold. |