From eaac527a2821c41aa88c8767fd0305f9d610fb23 Mon Sep 17 00:00:00 2001 From: Martin Nowack Date: Wed, 28 May 2014 22:35:45 +0200 Subject: Fix ExprTest under LLVM 2.9 --- include/klee/Expr.h | 3 +++ unittests/Expr/Makefile | 1 + 2 files changed, 4 insertions(+) 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 -- cgit 1.4.1