summaryrefslogtreecommitdiff
path: root/src/parser/smt1/Smt1.g
diff options
context:
space:
mode:
authorlianah <lianahady@gmail.com>2013-03-13 13:44:33 -0400
committerlianah <lianahady@gmail.com>2013-03-13 13:44:33 -0400
commit3fcdb18fe92e5213aa708285c0d7d5e55633492b (patch)
treebbbd57efd9a8063a976a55afa7c384fb67db9b17 /src/parser/smt1/Smt1.g
parent267ad0ceb6808bd4c05d7c4bb04a7886efc19eab (diff)
parent9817df56827b4ee0ee67a33361f8619c5d1df6ed (diff)
post failed attempts at getting the incremental solver to work
Diffstat (limited to 'src/parser/smt1/Smt1.g')
-rw-r--r--src/parser/smt1/Smt1.g17
1 files changed, 12 insertions, 5 deletions
diff --git a/src/parser/smt1/Smt1.g b/src/parser/smt1/Smt1.g
index 0f76baace..f8331c899 100644
--- a/src/parser/smt1/Smt1.g
+++ b/src/parser/smt1/Smt1.g
@@ -1,3 +1,4 @@
+/* ******************* */
/*! \file Smt1.g
** \verbatim
** Original author: cconway
@@ -30,10 +31,8 @@ options {
@header {
/**
- ** This file is part of the CVC4 prototype.
- ** Copyright (c) 2009, 2010, 2011 The Analysis of Computer Systems Group (ACSys)
- ** Courant Institute of Mathematical Sciences
- ** New York University
+ ** This file is part of CVC4.
+ ** Copyright (c) 2009-2013 New York University and The University of Iowa
** See the file COPYING in the top-level source directory for licensing
** information.
**/
@@ -783,7 +782,15 @@ FLET_IDENTIFIER
*/
userValue[std::string& s]
: USER_VALUE
- { s = AntlrInput::tokenText($USER_VALUE); }
+ { s = AntlrInput::tokenText($USER_VALUE);
+ assert(*s.begin() == '{');
+ assert(*s.rbegin() == '}');
+ // trim whitespace
+ s.erase(s.begin(), s.begin() + 1);
+ s.erase(s.begin(), std::find_if(s.begin(), s.end(), std::not1(std::ptr_fun<int, int>(std::isspace))));
+ s.erase(s.end() - 1);
+ s.erase(std::find_if(s.rbegin(), s.rend(), std::not1(std::ptr_fun<int, int>(std::isspace))).base(), s.end());
+ }
;
PATTERN_ANNOTATION_BEGIN
generated by cgit on debian on lair
contact matthew@masot.net with questions or feedback