about summary refs log tree commit diff homepage
path: root/lib
diff options
context:
space:
mode:
authorDan Liew <daniel.liew@imperial.ac.uk>2016-02-23 17:25:07 +0000
committerDan Liew <daniel.liew@imperial.ac.uk>2016-02-23 17:26:08 +0000
commit9bc1d11162403e331e99d5d0494feab70ace6fbc (patch)
treea0ee2f2270aed0cdce2f30e903d3c6387b1693b9 /lib
parent238998f8e17b554d0c28931a61271619310a098f (diff)
downloadklee-9bc1d11162403e331e99d5d0494feab70ace6fbc.tar.gz
When calling ``Assignment::dump()`` if there are no bindings emit
a message stating this.
Diffstat (limited to 'lib')
-rw-r--r--lib/Expr/Assigment.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/Expr/Assigment.cpp b/lib/Expr/Assigment.cpp
index 900c6d10..635362d4 100644
--- a/lib/Expr/Assigment.cpp
+++ b/lib/Expr/Assigment.cpp
@@ -10,6 +10,10 @@
 namespace klee {
 
 void Assignment::dump() {
+  if (bindings.size() == 0) {
+    llvm::errs() << "No bindings\n";
+    return;
+  }
   for (bindings_ty::iterator i = bindings.begin(), e = bindings.end(); i != e;
        ++i) {
     llvm::errs() << (*i).first->name << "\n[";