aboutsummaryrefslogtreecommitdiffstats
path: root/lib/Support/ConstantRange.cpp
diff options
context:
space:
mode:
authorReid Spencer <rspencer@reidspencer.com>2007-01-08 05:34:39 +0000
committerReid Spencer <rspencer@reidspencer.com>2007-01-08 05:34:39 +0000
commitca7ad8942a42eaf70d3ee3fa87d6a8211f4b5689 (patch)
treef53c5519ba7bb1d660d00c57e13acc4973e58e1c /lib/Support/ConstantRange.cpp
parentbb7a62435264f8f00ae502fcf985a3956d914cd4 (diff)
downloadexternal_llvm-ca7ad8942a42eaf70d3ee3fa87d6a8211f4b5689.zip
external_llvm-ca7ad8942a42eaf70d3ee3fa87d6a8211f4b5689.tar.gz
external_llvm-ca7ad8942a42eaf70d3ee3fa87d6a8211f4b5689.tar.bz2
Fix a bug in an assert that would never trigger.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@33005 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Support/ConstantRange.cpp')
-rw-r--r--lib/Support/ConstantRange.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/Support/ConstantRange.cpp b/lib/Support/ConstantRange.cpp
index 33a6702..a8ffa58 100644
--- a/lib/Support/ConstantRange.cpp
+++ b/lib/Support/ConstantRange.cpp
@@ -355,7 +355,7 @@ ConstantRange ConstantRange::zeroExtend(const Type *Ty) const {
/// truncated to the specified type.
ConstantRange ConstantRange::truncate(const Type *Ty) const {
unsigned SrcTySize = getLower()->getType()->getPrimitiveSizeInBits();
- assert(SrcTySize > Ty->getPrimitiveSize() && "Not a value truncation");
+ assert(SrcTySize > Ty->getPrimitiveSizeInBits() && "Not a value truncation");
uint64_t Size = 1ULL << Ty->getPrimitiveSizeInBits();
if (isFullSet() || getSetSize() >= Size)
return ConstantRange(getType());