about summary refs log tree commit diff homepage
diff options
context:
space:
mode:
authorMartin Nowack <martin@se.inf.tu-dresden.de>2014-05-28 22:35:45 +0200
committerMartin Nowack <martin@se.inf.tu-dresden.de>2014-05-30 00:06:36 +0200
commiteaac527a2821c41aa88c8767fd0305f9d610fb23 (patch)
treea3b45da7700f765408b1236eeefd4d1ec01e22bb
parent48492cbfa729fe035b7b69b71b541cb67f8545df (diff)
downloadklee-eaac527a2821c41aa88c8767fd0305f9d610fb23.tar.gz
Fix ExprTest under LLVM 2.9
-rw-r--r--include/klee/Expr.h3
-rw-r--r--unittests/Expr/Makefile1
2 files changed, 4 insertions, 0 deletions
diff --git a/include/klee/Expr.h b/include/klee/Expr.h
index ae5bfd2b..c78cd690 100644
--- a/include/klee/Expr.h
+++ b/include/klee/Expr.h
@@ -298,10 +298,13 @@ inline llvm::raw_ostream &operator<<(llvm::raw_ostream &os, const Expr &e) {
   return os;
 }
 
+// XXX the following macro is to work around the ExprTest unit test compile error
+#ifndef LLVM_29_UNITTEST
 inline llvm::raw_ostream &operator<<(llvm::raw_ostream &os, const Expr::Kind kind) {
   Expr::printKind(os, kind);
   return os;
 }
+#endif
 
 inline std::stringstream &operator<<(std::stringstream &os, const Expr &e) {
   std::string str;
diff --git a/unittests/Expr/Makefile b/unittests/Expr/Makefile
index f1cd4ec4..a9bfeda1 100644
--- a/unittests/Expr/Makefile
+++ b/unittests/Expr/Makefile
@@ -9,4 +9,5 @@ LINK_COMPONENTS := support
 
 include $(LLVM_SRC_ROOT)/unittests/Makefile.unittest
 
+CXXFLAGS += -DLLVM_29_UNITTEST
 LIBS += -lstp