mirror of
https://github.com/Z3Prover/z3
synced 2025-04-08 10:25:18 +00:00
update test in qe_arith
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
This commit is contained in:
parent
196aed785e
commit
1741671a9c
|
@ -168,7 +168,7 @@ namespace qe {
|
|||
unsigned find_max(model& mdl, bool do_pos) {
|
||||
unsigned result;
|
||||
bool found = false;
|
||||
rational found_val(0), r;
|
||||
rational found_val(0), r, found_c;
|
||||
expr_ref val(m);
|
||||
for (unsigned i = 0; i < m_ineq_terms.size(); ++i) {
|
||||
rational const& ac = m_ineq_coeffs[i];
|
||||
|
@ -180,11 +180,15 @@ namespace qe {
|
|||
if (!found || r > found_val) {
|
||||
result = i;
|
||||
found_val = r;
|
||||
found_c = ac;
|
||||
found = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
SASSERT(found);
|
||||
if (a.is_int(m_var->x()) && !found_c.is_one()) {
|
||||
throw cant_project();
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue