Skip to content

Commit 7fb6497

Browse files
fix return value when in external mode bool-flip
return null_bool_var instead of false (= 0).
1 parent d4f2de7 commit 7fb6497

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

src/ast/sls/sat_ddfw.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -161,7 +161,7 @@ namespace sat {
161161
if (m_unsat_vars.empty())
162162
return null_bool_var;
163163
if (m_in_external_flip)
164-
return false;
164+
return null_bool_var;
165165
return m_unsat_vars.elem_at(m_rand(m_unsat_vars.size()));
166166
}
167167

src/ast/sls/sls_arith_clausal.cpp

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -276,7 +276,9 @@ namespace sls {
276276
for (sat::bool_var bv = 0; bv < ctx.num_bool_vars(); ++bv) {
277277
if (a.get_ineq(bv) && a.get_ineq(bv)->is_true() != ctx.is_true(bv)) {
278278
TRACE("arith", tout << "bv:" << bv << " " << *a.get_ineq(bv) << ctx.is_true(bv) << "\n";
279-
tout << "bool vars: " << a.m_vars[v].m_bool_vars_of << "\n");
279+
tout << "v" << v << " bool vars: " << a.m_vars[v].m_bool_vars_of << "\n";
280+
tout << mk_bounded_pp(a.m_vars[v].m_expr, a.m) << "\n";
281+
tout << mk_bounded_pp(ctx.atom(bv), a.m) << "\n");
280282
}
281283
VERIFY(!a.get_ineq(bv) || a.get_ineq(bv)->is_true() == ctx.is_true(bv));
282284
});

0 commit comments

Comments
 (0)