3
0
Fork 0
mirror of https://github.com/Z3Prover/z3 synced 2025-04-28 19:35:50 +00:00

change lar_terms to use column indices

Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
This commit is contained in:
Nikolaj Bjorner 2020-04-06 11:51:06 -07:00
parent 3313590b95
commit c2e5cd78c8
13 changed files with 88 additions and 103 deletions

View file

@ -86,7 +86,7 @@ namespace lp {
bool seen_minus = false;
bool seen_plus = false;
for(const auto & p : t) {
if (!lia.column_is_int(p.var().index()))
if (!lia.column_is_int(p.column()))
goto usual_delta;
const mpq & c = p.coeff();
if (c == one_of_type<mpq>()) {
@ -104,7 +104,7 @@ namespace lp {
usual_delta:
mpq delta = zero_of_type<mpq>();
for (const auto & p : t)
if (lia.column_is_int(p.var().index()))
if (lia.column_is_int(p.column()))
delta += abs(p.coeff());
delta *= mpq(1, 2);