about summary refs log tree commit diff homepage
path: root/lib/Expr/Expr.cpp
diff options
context:
space:
mode:
authorCristian Cadar <cristic@cs.stanford.edu>2011-04-23 19:22:22 +0000
committerCristian Cadar <cristic@cs.stanford.edu>2011-04-23 19:22:22 +0000
commit930ae7d06fc1d8cc3117397cb3fd168a0a1090b7 (patch)
treeac1ff2162b5ea6d51bbf6a1ac35f350a297234ac /lib/Expr/Expr.cpp
parent2ec715a7e08724e54cd8c14904446d1b91b42121 (diff)
downloadklee-930ae7d06fc1d8cc3117397cb3fd168a0a1090b7.tar.gz
Patch by arrowdodger (http://keeda.stanford.edu/pipermail/klee-dev/2011-April/000617.html) for compiling KLEE with the latest LLVM changes. Tested against LLVM 2.7 and 2.8. The AsmAddresses test fails in 2.8 unless assertions are explicitely enabled (--enable-assertions).
git-svn-id: https://llvm.org/svn/llvm-project/klee/trunk@130065 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Expr/Expr.cpp')
-rw-r--r--lib/Expr/Expr.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/Expr/Expr.cpp b/lib/Expr/Expr.cpp
index 71e64325..e02a7e49 100644
--- a/lib/Expr/Expr.cpp
+++ b/lib/Expr/Expr.cpp
@@ -336,7 +336,11 @@ void ConstantExpr::toString(std::string &Res) const {
 ref<ConstantExpr> ConstantExpr::Concat(const ref<ConstantExpr> &RHS) {
   Expr::Width W = getWidth() + RHS->getWidth();
   APInt Tmp(value);
+#if (LLVM_VERSION_MAJOR < 3)
   Tmp.zext(W);
+#else
+  Tmp=Tmp.zext(W);
+#endif
   Tmp <<= RHS->getWidth();
   Tmp |= APInt(RHS->value).zext(W);