aboutsummaryrefslogtreecommitdiff
path: root/lib/Transforms/Utils/LowerSwitch.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'lib/Transforms/Utils/LowerSwitch.cpp')
-rw-r--r--lib/Transforms/Utils/LowerSwitch.cpp4
1 files changed, 1 insertions, 3 deletions
diff --git a/lib/Transforms/Utils/LowerSwitch.cpp b/lib/Transforms/Utils/LowerSwitch.cpp
index b2974a98c8..bcbadd0040 100644
--- a/lib/Transforms/Utils/LowerSwitch.cpp
+++ b/lib/Transforms/Utils/LowerSwitch.cpp
@@ -59,9 +59,7 @@ namespace {
const ConstantInt* CI1 = cast<const ConstantInt>(C1.first);
const ConstantInt* CI2 = cast<const ConstantInt>(C2.first);
- if (CI1->getType()->isUnsigned())
- return CI1->getZExtValue() < CI2->getZExtValue();
- return CI1->getSExtValue() < CI2->getSExtValue();
+ return CI1->getZExtValue() < CI2->getZExtValue();
}
};