about summary refs log tree commit diff homepage
path: root/lib/Expr
diff options
context:
space:
mode:
authorMartin Nowack <m.nowack@imperial.ac.uk>2019-03-27 11:33:07 +0000
committerCristian Cadar <c.cadar@imperial.ac.uk>2020-07-01 15:52:40 +0100
commitf56c7aa2a7200ece5d074651b9839eb917f910f5 (patch)
treecd4224cc8fb731efdec0b37a1890ab10eb5070da /lib/Expr
parentd591cba305cb86ee8c520b7ff427651d8f9e0f31 (diff)
downloadklee-f56c7aa2a7200ece5d074651b9839eb917f910f5.tar.gz
Move constraint implementation from header to cpp files
Diffstat (limited to 'lib/Expr')
-rw-r--r--lib/Expr/Constraints.cpp25
1 files changed, 21 insertions, 4 deletions
diff --git a/lib/Expr/Constraints.cpp b/lib/Expr/Constraints.cpp
index 89e2ca59..1c7bee57 100644
--- a/lib/Expr/Constraints.cpp
+++ b/lib/Expr/Constraints.cpp
@@ -95,10 +95,6 @@ bool ConstraintManager::rewriteConstraints(ExprVisitor &visitor) {
   return changed;
 }
 
-void ConstraintManager::simplifyForValidConstraint(ref<Expr> e) {
-  // XXX 
-}
-
 ref<Expr> ConstraintManager::simplifyExpr(ref<Expr> e) const {
   if (isa<ConstantExpr>(e))
     return e;
@@ -168,3 +164,24 @@ void ConstraintManager::addConstraint(ref<Expr> e) {
   e = simplifyExpr(e);
   addConstraintInternal(e);
 }
+
+ConstraintManager::ConstraintManager(const std::vector<ref<Expr>> &_constraints)
+    : constraints(_constraints) {}
+
+bool ConstraintManager::empty() const { return constraints.empty(); }
+
+klee::ref<Expr> ConstraintManager::back() const { return constraints.back(); }
+
+klee::ConstraintManager::constraint_iterator ConstraintManager::begin() const {
+  return constraints.begin();
+}
+
+klee::ConstraintManager::constraint_iterator ConstraintManager::end() const {
+  return constraints.end();
+}
+
+size_t ConstraintSet::size() const noexcept { return constraints.size(); }
+
+bool ConstraintManager::operator==(const ConstraintManager &other) const {
+  return constraints == other.constraints;
+}