3
0
Fork 0
mirror of https://github.com/Z3Prover/z3 synced 2026-08-04 05:03:30 +00:00

Remove unnecessary semicolons (Attempt 2) (#10020)

This is another PR towards the goal of getting Z3 to compile cleanly
when included via FetchContents into clang-tidy, which uses a pretty
strict set of warnings.

This is a second version of https://github.com/Z3Prover/z3/pull/9957. I
address @NikolajBjorner 's comments about not changing the semicolons
after macro invocations, because some editors work better with them
present. It now, to the best of my ability, only deletes semis:

* after the closing brace of namespace decl.
* after the closing brace of an extern "C" decl.
* after a function definition.

This PR is very large, but it consists entirely of deletions of
semicolons in these situations.

(If there was a way to update the previous PR, which had been closed,
and that is preferable, please let me know. I couldn't figure it out.)
This commit is contained in:
davedets 2026-07-02 12:47:29 -07:00 committed by GitHub
parent 69444de05b
commit 6ac3075022
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
429 changed files with 477 additions and 476 deletions

View file

@ -33,5 +33,5 @@ namespace opt {
maxsmt_solver_base* mk_primal_dual_maxres(maxsat_context& c, unsigned id, vector<soft>& soft);
};
}

View file

@ -26,5 +26,5 @@ namespace opt {
maxsmt_solver_base* mk_maxlex(maxsat_context& c, unsigned id, vector<soft>& soft);
};
}

View file

@ -380,12 +380,12 @@ namespace opt {
params_ref& params() override { return m_params; }
void enable_sls(bool force) override { } // no op
symbol const& maxsat_engine() const override { return m_maxsat_engine; }
void get_base_model(model_ref& _m) override { _m = m_model; };
void get_base_model(model_ref& _m) override { _m = m_model; }
smt::context& smt_context() override {
throw default_exception("stand-alone maxsat context does not support wmax");
}
unsigned num_objectives() override { return 1; }
bool verify_model(unsigned id, model* mdl, rational const& v) override { return true; };
bool verify_model(unsigned id, model* mdl, rational const& v) override { return true; }
void set_model(model_ref& _m) override { m_model = _m; }
void model_updated(model* mdl) override { } // no-op
rational adjust(unsigned id, rational const& r) override {
@ -419,4 +419,4 @@ namespace opt {
}
return r;
}
};
}

View file

@ -211,5 +211,5 @@ namespace opt {
model_ref get_model() { return m_model; }
};
};
}

View file

@ -394,4 +394,4 @@ namespace opt {
}
}
};
}

View file

@ -68,4 +68,4 @@ namespace opt {
void updt_params(params_ref& p);
};
};
}

View file

@ -269,4 +269,4 @@ namespace opt {
return r;
}
};
}

View file

@ -77,4 +77,4 @@ namespace opt {
void set_conflicts(unsigned c) { m_max_conflicts = c; }
unsigned climb(model_ref& mdl);
};
};
}

View file

@ -238,4 +238,4 @@ namespace opt {
return false;
return true;
}
};
}

View file

@ -40,4 +40,4 @@ namespace opt {
preprocess(solver& s);
bool operator()(vector<soft>& soft, rational& lower);
};
};
}

View file

@ -93,5 +93,5 @@ namespace opt {
};
};
}

View file

@ -44,5 +44,5 @@ namespace smt {
};
};
}