mirror of
https://github.com/Z3Prover/z3
synced 2025-06-08 15:13:23 +00:00
Refactoring
This commit is contained in:
parent
ec8f99fee7
commit
a696a40a3a
2 changed files with 27 additions and 16 deletions
|
@ -2981,6 +2981,24 @@ bool context::is_reachable(pob &n)
|
||||||
return next ? is_reachable(*next) : true;
|
return next ? is_reachable(*next) : true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void context::dump_json()
|
||||||
|
{
|
||||||
|
if(m_params.spacer_print_json().size()) {
|
||||||
|
std::ofstream of;
|
||||||
|
of.open(m_params.spacer_print_json().bare_str());
|
||||||
|
m_json_marshaller.marshal(of);
|
||||||
|
of.close();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
void context::predecessor_eh()
|
||||||
|
{
|
||||||
|
for (unsigned i = 0; i < m_callbacks.size(); i++) {
|
||||||
|
if(m_callbacks[i]->predecessor())
|
||||||
|
m_callbacks[i]->predecessor_eh();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
//this processes a goal and creates sub-goal
|
//this processes a goal and creates sub-goal
|
||||||
lbool context::expand_pob(pob& n)
|
lbool context::expand_pob(pob& n)
|
||||||
{
|
{
|
||||||
|
@ -3040,10 +3058,7 @@ lbool context::expand_pob(pob& n)
|
||||||
tout << "This pob can be blocked by instantiation\n";);
|
tout << "This pob can be blocked by instantiation\n";);
|
||||||
}
|
}
|
||||||
|
|
||||||
for (unsigned i = 0; i < m_callbacks.size(); i++){
|
predecessor_eh();
|
||||||
if(m_callbacks[i]->predecessor())
|
|
||||||
m_callbacks[i]->predecessor_eh();
|
|
||||||
}
|
|
||||||
|
|
||||||
lbool res = n.pt ().is_reachable (n, &cube, &model, uses_level, is_concrete, r,
|
lbool res = n.pt ().is_reachable (n, &cube, &model, uses_level, is_concrete, r,
|
||||||
reach_pred_used, num_reuse_reach);
|
reach_pred_used, num_reuse_reach);
|
||||||
|
@ -3106,8 +3121,9 @@ lbool context::expand_pob(pob& n)
|
||||||
return l_undef;
|
return l_undef;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
case l_false:
|
||||||
// n is unreachable, create new summary facts
|
// n is unreachable, create new summary facts
|
||||||
case l_false: {
|
{
|
||||||
timeit _timer (is_trace_enabled("spacer_timeit"),
|
timeit _timer (is_trace_enabled("spacer_timeit"),
|
||||||
"spacer::expand_pob::false",
|
"spacer::expand_pob::false",
|
||||||
verbose_stream ());
|
verbose_stream ());
|
||||||
|
|
|
@ -824,14 +824,9 @@ class context {
|
||||||
|
|
||||||
unsigned get_cex_depth ();
|
unsigned get_cex_depth ();
|
||||||
|
|
||||||
void dump_json() {
|
void dump_json();
|
||||||
if(m_params.spacer_print_json().size()) {
|
|
||||||
std::ofstream of;
|
void predecessor_eh();
|
||||||
of.open(m_params.spacer_print_json().bare_str());
|
|
||||||
m_json_marshaller.marshal(of);
|
|
||||||
of.close();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
public:
|
public:
|
||||||
/**
|
/**
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue