mirror of
https://github.com/Z3Prover/z3
synced 2025-07-20 03:12:03 +00:00
removing iterators
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
This commit is contained in:
parent
936c22a00b
commit
320105c714
2 changed files with 6 additions and 17 deletions
|
@ -2016,26 +2016,20 @@ namespace smt {
|
||||||
void execute(code_tree * t) {
|
void execute(code_tree * t) {
|
||||||
TRACE("trigger_bug", tout << "execute for code tree:\n"; t->display(tout););
|
TRACE("trigger_bug", tout << "execute for code tree:\n"; t->display(tout););
|
||||||
init(t);
|
init(t);
|
||||||
enode_vector::const_iterator it = t->get_candidates().begin();
|
|
||||||
enode_vector::const_iterator end = t->get_candidates().end();
|
|
||||||
if (t->filter_candidates()) {
|
if (t->filter_candidates()) {
|
||||||
for (; it != end; ++it) {
|
for (enode * app : t->get_candidates()) {
|
||||||
enode * app = *it;
|
|
||||||
if (!app->is_marked() && app->is_cgr()) {
|
if (!app->is_marked() && app->is_cgr()) {
|
||||||
execute_core(t, app);
|
execute_core(t, app);
|
||||||
app->set_mark();
|
app->set_mark();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
it = t->get_candidates().begin();
|
for (enode * app : t->get_candidates()) {
|
||||||
for (; it != end; ++it) {
|
|
||||||
enode * app = *it;
|
|
||||||
if (app->is_marked())
|
if (app->is_marked())
|
||||||
app->unset_mark();
|
app->unset_mark();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
for (; it != end; ++it) {
|
for (enode * app : t->get_candidates()) {
|
||||||
enode * app = *it;
|
|
||||||
TRACE("trigger_bug", tout << "candidate\n" << mk_ismt2_pp(app->get_owner(), m_ast_manager) << "\n";);
|
TRACE("trigger_bug", tout << "candidate\n" << mk_ismt2_pp(app->get_owner(), m_ast_manager) << "\n";);
|
||||||
if (app->is_cgr()) {
|
if (app->is_cgr()) {
|
||||||
TRACE("trigger_bug", tout << "is_cgr\n";);
|
TRACE("trigger_bug", tout << "is_cgr\n";);
|
||||||
|
@ -2821,15 +2815,13 @@ namespace smt {
|
||||||
} // end of execute_core
|
} // end of execute_core
|
||||||
|
|
||||||
void display_trees(std::ostream & out, const ptr_vector<code_tree> & trees) {
|
void display_trees(std::ostream & out, const ptr_vector<code_tree> & trees) {
|
||||||
ptr_vector<code_tree>::const_iterator it = trees.begin();
|
|
||||||
ptr_vector<code_tree>::const_iterator end = trees.end();
|
|
||||||
unsigned lbl = 0;
|
unsigned lbl = 0;
|
||||||
for (; it != end; ++it, ++lbl) {
|
for (code_tree* tree : trees) {
|
||||||
code_tree * tree = *it;
|
|
||||||
if (tree) {
|
if (tree) {
|
||||||
out << "tree for f" << lbl << "\n";
|
out << "tree for f" << lbl << "\n";
|
||||||
out << *tree;
|
out << *tree;
|
||||||
}
|
}
|
||||||
|
++lbl;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -148,11 +148,8 @@ namespace smt {
|
||||||
}
|
}
|
||||||
|
|
||||||
void qi_queue::instantiate() {
|
void qi_queue::instantiate() {
|
||||||
svector<entry>::iterator it = m_new_entries.begin();
|
|
||||||
svector<entry>::iterator end = m_new_entries.end();
|
|
||||||
unsigned since_last_check = 0;
|
unsigned since_last_check = 0;
|
||||||
for (; it != end; ++it) {
|
for (entry & curr : m_new_entries) {
|
||||||
entry & curr = *it;
|
|
||||||
fingerprint * f = curr.m_qb;
|
fingerprint * f = curr.m_qb;
|
||||||
quantifier * qa = static_cast<quantifier*>(f->get_data());
|
quantifier * qa = static_cast<quantifier*>(f->get_data());
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue