mirror of
https://github.com/Z3Prover/z3
synced 2025-04-24 01:25:31 +00:00
roll back changes in get_model
Signed-off-by: Lev Nachmanson <levnach@hotmail.com>
This commit is contained in:
parent
0dbe8982ce
commit
b6f07e2a23
4 changed files with 6 additions and 8 deletions
|
@ -1489,7 +1489,7 @@ public:
|
|||
}
|
||||
|
||||
lp::var_index vi = m_theory_var2var_index[v];
|
||||
if (vi < m_variable_values.size())
|
||||
if (m_variable_values.count(vi) > 0)
|
||||
return m_variable_values[vi];
|
||||
|
||||
if (!m_solver->is_term(vi)) {
|
||||
|
@ -1505,7 +1505,7 @@ public:
|
|||
if (m_solver->is_term(wi)) {
|
||||
const lp::lar_term& term = m_solver->get_term(wi);
|
||||
for (const auto & i : term) {
|
||||
if (i.var() < m_variable_values.size()) {
|
||||
if (m_variable_values.count(i.var()) > 0) {
|
||||
result += m_variable_values[i.var()] * coeff * i.coeff();
|
||||
}
|
||||
else {
|
||||
|
@ -1517,7 +1517,7 @@ public:
|
|||
result += m_variable_values[wi] * coeff;
|
||||
}
|
||||
}
|
||||
m_term_values[vi] = result;
|
||||
m_variable_values[vi] = result;
|
||||
return result;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue