mirror of
https://github.com/Z3Prover/z3
synced 2026-01-23 02:24:01 +00:00
Standardize for-loop increments to prefix form (++i) (#8199)
* Initial plan * Convert postfix to prefix increment in for loops Co-authored-by: NikolajBjorner <3085284+NikolajBjorner@users.noreply.github.com> * Fix member variable increment conversion bug Co-authored-by: NikolajBjorner <3085284+NikolajBjorner@users.noreply.github.com> * Update API generator to produce prefix increments Co-authored-by: NikolajBjorner <3085284+NikolajBjorner@users.noreply.github.com> --------- Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: NikolajBjorner <3085284+NikolajBjorner@users.noreply.github.com>
This commit is contained in:
parent
1bf463d77a
commit
2436943794
475 changed files with 3237 additions and 3237 deletions
|
|
@ -91,7 +91,7 @@ class skolemizer {
|
|||
unsigned sz = m_uv.get_max_found_var_idx_plus_1();
|
||||
ptr_buffer<sort> sorts;
|
||||
expr_ref_vector args(m);
|
||||
for (unsigned i = 0; i < sz; i++) {
|
||||
for (unsigned i = 0; i < sz; ++i) {
|
||||
sort * s = m_uv.get(i);
|
||||
if (s != nullptr) {
|
||||
sorts.push_back(s);
|
||||
|
|
@ -114,7 +114,7 @@ class skolemizer {
|
|||
// (VAR 0) is in the first position of substitution.
|
||||
// (VAR num_decls-1) is in the last position.
|
||||
//
|
||||
for (unsigned i = 0; i < sz; i++) {
|
||||
for (unsigned i = 0; i < sz; ++i) {
|
||||
sort * s = m_uv.get(i);
|
||||
if (s != nullptr)
|
||||
substitution.push_back(m.mk_var(i, s));
|
||||
|
|
@ -272,7 +272,7 @@ struct nnf::imp {
|
|||
m_result_pr_stack(m),
|
||||
m_skolemizer(m) {
|
||||
updt_params(p);
|
||||
for (unsigned i = 0; i < 4; i++) {
|
||||
for (unsigned i = 0; i < 4; ++i) {
|
||||
if (proofs_enabled())
|
||||
m_cache_pr[i] = alloc(act_cache, m);
|
||||
}
|
||||
|
|
@ -283,7 +283,7 @@ struct nnf::imp {
|
|||
bool proofs_enabled() const { return m.proofs_enabled(); }
|
||||
|
||||
~imp() {
|
||||
for (unsigned i = 0; i < 4; i++) {
|
||||
for (unsigned i = 0; i < 4; ++i) {
|
||||
if (proofs_enabled())
|
||||
dealloc(m_cache_pr[i]);
|
||||
}
|
||||
|
|
@ -323,7 +323,7 @@ struct nnf::imp {
|
|||
}
|
||||
|
||||
void reset_cache() {
|
||||
for (unsigned i = 0; i < 4; i++) {
|
||||
for (unsigned i = 0; i < 4; ++i) {
|
||||
m_cache[i].reset();
|
||||
if (proofs_enabled())
|
||||
m_cache_pr[i]->reset();
|
||||
|
|
@ -783,7 +783,7 @@ struct nnf::imp {
|
|||
if (is_forall(q) == fr.m_pol) {
|
||||
// collect non sk_hack patterns
|
||||
unsigned num_patterns = q->get_num_patterns();
|
||||
for (unsigned i = 0; i < num_patterns; i++) {
|
||||
for (unsigned i = 0; i < num_patterns; ++i) {
|
||||
expr * pat = q->get_pattern(i);
|
||||
if (!m_skolemizer.is_sk_hack(pat))
|
||||
new_patterns.push_back(pat);
|
||||
|
|
@ -899,7 +899,7 @@ struct nnf::imp {
|
|||
unsigned old_sz1 = new_defs.size();
|
||||
unsigned old_sz2 = new_def_proofs.size();
|
||||
|
||||
for (unsigned i = 0; i < m_todo_defs.size(); i++) {
|
||||
for (unsigned i = 0; i < m_todo_defs.size(); ++i) {
|
||||
expr_ref dr(m);
|
||||
proof_ref dpr(m);
|
||||
process(m_todo_defs.get(i), dr, dpr);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue