Skip to content

Commit

Permalink
fix variable tracking bug in explanations with literals
Browse files Browse the repository at this point in the history
  • Loading branch information
NikolajBjorner committed Sep 2, 2022
1 parent eb1ea94 commit e4ef171
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/sat/smt/euf_internalize.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -167,7 +167,7 @@ namespace euf {
lit = lit2;
}

TRACE("euf", tout << "attach " << v << " " << mk_bounded_pp(e, m) << "\n";);
TRACE("euf", tout << "attach v" << v << " " << mk_bounded_pp(e, m) << "\n";);
m_bool_var2expr.reserve(v + 1, nullptr);
if (m_bool_var2expr[v] && m_egraph.find(e)) {
if (m_egraph.find(e)->bool_var() != v) {
Expand Down
5 changes: 3 additions & 2 deletions src/sat/smt/euf_proof.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -83,10 +83,11 @@ namespace euf {
expr_ref_vector eqs(m);
unsigned nv = s().num_vars();
auto add_lit = [&](enode_pair const& eq) {
unsigned v = nv;
++nv;
eqs.push_back(m.mk_eq(eq.first->get_expr(), eq.second->get_expr()));
set_tmp_bool_var(nv, eqs.back());
return literal(nv, false);
set_tmp_bool_var(v, eqs.back());
return literal(v, false);
};

for (auto lit : euf::th_explain::lits(jst))
Expand Down

0 comments on commit e4ef171

Please sign in to comment.