mirror of
https://github.com/Z3Prover/z3
synced 2025-12-24 13:06:50 +00:00
parent
eb56ac48b0
commit
cb5fb390bc
2 changed files with 6 additions and 1 deletions
|
|
@ -458,6 +458,7 @@ namespace opt {
|
|||
|
||||
void context::set_model(model_ref& m) {
|
||||
m_model = m;
|
||||
m_model_available = true;
|
||||
opt_params optp(m_params);
|
||||
symbol prefix = optp.solution_prefix();
|
||||
bool model2console = optp.dump_models();
|
||||
|
|
@ -490,6 +491,8 @@ namespace opt {
|
|||
|
||||
|
||||
void context::get_model_core(model_ref& mdl) {
|
||||
if (!m_model_available)
|
||||
throw default_exception("model is not available");
|
||||
mdl = m_model;
|
||||
CTRACE(opt, mdl, tout << *mdl;);
|
||||
fix_model(mdl);
|
||||
|
|
@ -1730,6 +1733,7 @@ namespace opt {
|
|||
m_model.reset();
|
||||
m_model_fixed.reset();
|
||||
m_core.reset();
|
||||
m_model_available = false;
|
||||
}
|
||||
|
||||
void context::set_pareto(pareto_base* p) {
|
||||
|
|
|
|||
|
|
@ -186,7 +186,8 @@ namespace opt {
|
|||
map_t m_maxsmts;
|
||||
scoped_state m_scoped_state;
|
||||
vector<objective> m_objectives;
|
||||
model_ref m_model;
|
||||
model_ref m_model;
|
||||
bool m_model_available = false;
|
||||
model_converter_ref m_model_converter;
|
||||
generic_model_converter_ref m_fm;
|
||||
sref_vector<model> m_model_fixed;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue