summaryrefslogtreecommitdiffstats
path: root/llvm/lib/VMCore/Constants.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'llvm/lib/VMCore/Constants.cpp')
-rw-r--r--llvm/lib/VMCore/Constants.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/lib/VMCore/Constants.cpp b/llvm/lib/VMCore/Constants.cpp
index d3a6a2502ad..3e5cd78d442 100644
--- a/llvm/lib/VMCore/Constants.cpp
+++ b/llvm/lib/VMCore/Constants.cpp
@@ -442,7 +442,7 @@ bool ConstantSInt::isValueValidForType(const Type *Ty, int64_t Val) {
case Type::ShortTyID:
return (Val <= INT16_MAX && Val >= INT16_MIN);
case Type::IntTyID:
- return (Val <= INT32_MAX && Val >= INT32_MIN);
+ return (Val <= int(INT32_MAX) && Val >= int(INT32_MIN));
case Type::LongTyID:
return true; // This is the largest type...
}
OpenPOWER on IntegriCloud