3
0
Fork 0
mirror of https://github.com/Z3Prover/z3 synced 2025-05-04 14:25:46 +00:00
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
This commit is contained in:
Nikolaj Bjorner 2015-12-10 19:20:16 -08:00
parent 30580a012a
commit 5eb23e1e7a
17 changed files with 287 additions and 141 deletions

View file

@ -222,8 +222,10 @@ ATOMIC_CMD(reset_assertions_cmd, "reset-assertions", "reset all asserted formula
UNARY_CMD(set_logic_cmd, "set-logic", "<symbol>", "set the background logic.", CPK_SYMBOL, symbol const &,
if (ctx.set_logic(arg))
ctx.print_success();
else
ctx.print_unsupported(symbol::null, m_line, m_pos);
else {
std::string msg = "ignoring unsupported logic " + arg.str();
ctx.print_unsupported(symbol(msg.c_str()), m_line, m_pos);
}
);
UNARY_CMD(pp_cmd, "display", "<term>", "display the given term.", CPK_EXPR, expr *, {

View file

@ -168,6 +168,11 @@ struct check_logic::imp {
m_bvs = true;
m_quantifiers = true;
}
else if (logic == "UF_S") {
m_uf = true;
m_bvs = true;
m_quantifiers = false;
}
else {
m_unknown_logic = true;
}

View file

@ -576,7 +576,7 @@ bool cmd_context::logic_has_bv() const {
}
bool cmd_context::logic_has_seq_core(symbol const& s) const {
return s == "QF_BVRE";
return s == "QF_BVRE" || s == "QF_S";
}
bool cmd_context::logic_has_seq() const {
@ -712,13 +712,7 @@ bool cmd_context::set_logic(symbol const & s) {
if (has_manager() && m_main_ctx)
throw cmd_exception("logic must be set before initialization");
if (!supported_logic(s)) {
if (m_params.m_smtlib2_compliant) {
return false;
}
else {
warning_msg("unknown logic, ignoring set-logic command");
return true;
}
return false;
}
m_logic = s;
if (is_logic("QF_RDL") ||