mirror of
https://github.com/Z3Prover/z3
synced 2025-04-08 10:25:18 +00:00
Fix termination conditions on core_maxsat
This commit is contained in:
parent
66eda866ca
commit
64daa2977d
|
@ -69,6 +69,10 @@ namespace opt {
|
|||
m_answer.reset();
|
||||
m_answer.append(ans);
|
||||
}
|
||||
if (m_answer.size() == m_upper) {
|
||||
return l_true;
|
||||
}
|
||||
SASSERT(m_soft.size() >= m_answer.size()+1);
|
||||
unsigned k = m_soft.size()-m_answer.size()-1;
|
||||
expr_ref fml = mk_at_most(core_vars, k);
|
||||
TRACE("opt", tout << "add: " << fml << "\n";);
|
||||
|
|
Loading…
Reference in a new issue