about summary refs log tree commit diff homepage
path: root/lib/SMT/SMTParser.cpp
diff options
context:
space:
mode:
authorCristian Cadar <cristic@cs.stanford.edu>2009-06-25 07:13:24 +0000
committerCristian Cadar <cristic@cs.stanford.edu>2009-06-25 07:13:24 +0000
commit553e2871ba937a91da303190631daf627f83eabb (patch)
treed331502b53465cb3f4f6aa36e62cab97fe7923e1 /lib/SMT/SMTParser.cpp
parent0da7412d643890e299cc83d8f09b8b90d0ae94bd (diff)
downloadklee-553e2871ba937a91da303190631daf627f83eabb.tar.gz
Recognizing more SMTLIB expressions (bitwise, etc.). Some of them
still need to actually be constructed.



git-svn-id: https://llvm.org/svn/llvm-project/klee/trunk@74169 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/SMT/SMTParser.cpp')
-rw-r--r--lib/SMT/SMTParser.cpp13
1 files changed, 12 insertions, 1 deletions
diff --git a/lib/SMT/SMTParser.cpp b/lib/SMT/SMTParser.cpp
index dee3801c..32e453f0 100644
--- a/lib/SMT/SMTParser.cpp
+++ b/lib/SMT/SMTParser.cpp
@@ -12,7 +12,8 @@
 
 #include <iostream>
 #include <fstream>
-#include <cstring>
+#include <string>
+#include <sstream>
 #include <cassert>
 #include <stack>
 
@@ -66,6 +67,16 @@ int SMTParser::Error(const string& s) {
   return 0;
 }
 
+
+int SMTParser::StringToInt(const std::string& s) {
+  std::stringstream str(s);
+  int x;
+  str >> x;
+  assert(str);
+  return x;
+}
+
+
 void SMTParser::PushVarEnv() {
   cout << "Pushing new var env\n";
   varEnvs.push(VarEnv(varEnvs.top()));