diff options
author | Morgan Deters <mdeters@gmail.com> | 2012-06-11 16:28:23 +0000 |
---|---|---|
committer | Morgan Deters <mdeters@gmail.com> | 2012-06-11 16:28:23 +0000 |
commit | 3378e253fcdb34c753407bb16d08929da06b3aaa (patch) | |
tree | db7c7118dd0d1594175b56866f845b42426ae0a7 /src/printer/smt2 | |
parent | 42794501e81c44dce5c2f7687af288af030ef63e (diff) |
Merge from quantifiers2-trunkmerge branch.
Adds TheoryQuantifiers and TheoryRewriteRules, QuantifiersEngine, and other infrastructure.
Adds theory instantiators to many theories.
Adds the UF strong solver.
Diffstat (limited to 'src/printer/smt2')
-rw-r--r-- | src/printer/smt2/smt2_printer.cpp | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/src/printer/smt2/smt2_printer.cpp b/src/printer/smt2/smt2_printer.cpp index 72ce3804d..ebec37031 100644 --- a/src/printer/smt2/smt2_printer.cpp +++ b/src/printer/smt2/smt2_printer.cpp @@ -281,6 +281,32 @@ void Smt2Printer::toStream(std::ostream& out, TNode n, case kind::APPLY_SELECTOR: break; + // quantifiers + case kind::FORALL: out << "forall "; break; + case kind::EXISTS: out << "exists "; break; + case kind::BOUND_VAR_LIST: + out << '('; + for(TNode::iterator i = n.begin(), + iend = n.end(); + i != iend; ) { + out << '('; + (*i).toStream(out, toDepth < 0 ? toDepth : toDepth - 1, + types, language::output::LANG_SMTLIB_V2); + out << ' '; + (*i).getType().toStream(out, toDepth < 0 ? toDepth : toDepth - 1, + false, language::output::LANG_SMTLIB_V2); + out << ')'; + if(++i != iend) { + out << ' '; + } + } + out << ')'; + return; + case kind::INST_PATTERN: + case kind::INST_PATTERN_LIST: + // TODO user patterns + break; + default: // fall back on however the kind prints itself; this probably // won't be SMT-LIB v2 compliant, but it will be clear from the |