3
0
Fork 0
mirror of https://github.com/Z3Prover/z3 synced 2025-07-18 02:16:40 +00:00

moving to resource managed cancellation

Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
This commit is contained in:
Nikolaj Bjorner 2015-12-11 13:13:11 -08:00
parent 61dbb6168e
commit 32b6b2da44
41 changed files with 55 additions and 280 deletions

View file

@ -578,8 +578,12 @@ void rewriter_tpl<Config>::resume_core(expr_ref & result, proof_ref & result_pr)
while (!frame_stack().empty()) {
if (m_cancel)
throw rewriter_exception(Z3_CANCELED_MSG);
if (!m().limit().inc())
if (!m().canceled()) {
if (m().limit().cancel_flag_set()) {
throw rewriter_exception(Z3_CANCELED_MSG);
}
throw rewriter_exception(Z3_MAX_RESOURCE_MSG);
}
SASSERT(!ProofGen || result_stack().size() == result_pr_stack().size());
frame & fr = frame_stack().back();
expr * t = fr.m_curr;