aboutsummaryrefslogtreecommitdiff
path: root/lib/Analysis/Expressions.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'lib/Analysis/Expressions.cpp')
-rw-r--r--lib/Analysis/Expressions.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/Analysis/Expressions.cpp b/lib/Analysis/Expressions.cpp
index e6f4cfa947..ed04f1d818 100644
--- a/lib/Analysis/Expressions.cpp
+++ b/lib/Analysis/Expressions.cpp
@@ -73,7 +73,8 @@ struct DefOne : public DefVal {
static ConstPoolInt *getUnsignedConstant(uint64_t V, const Type *Ty) {
if (Ty->isPointerType()) Ty = Type::ULongTy;
- return Ty->isSigned() ? ConstPoolSInt::get(Ty, V) : ConstPoolUInt::get(Ty, V);
+ return Ty->isSigned() ? (ConstPoolInt*)ConstPoolSInt::get(Ty, V)
+ : (ConstPoolInt*)ConstPoolUInt::get(Ty, V);
}
// Add - Helper function to make later code simpler. Basically it just adds