Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
NikolajBjorner committed Apr 1, 2022
1 parent c7922d6 commit 4cc3327
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions src/sat/smt/q_mam.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1893,7 +1893,8 @@ namespace q {
}

void recycle_enode_vector(enode_vector * v) {
m_pool.recycle(v);
if (v)
m_pool.recycle(v);
}

void update_max_generation(enode * n, enode * prev) {
Expand Down Expand Up @@ -2197,8 +2198,10 @@ namespace q {
if (curr->num_args() == expected_num_args && ctx.is_relevant(curr))
break;
}
if (bp.m_it == bp.m_end)
if (bp.m_it == bp.m_end) {
recycle_enode_vector(bp.m_to_recycle);
return nullptr;
}
m_top++;
update_max_generation(*(bp.m_it), nullptr);
return *(bp.m_it);
Expand Down

0 comments on commit 4cc3327

Please sign in to comment.