3
0
Fork 0
mirror of https://github.com/Z3Prover/z3 synced 2025-04-08 10:25:18 +00:00

mk_coeffs_without was inadvertently copying src.

Pass it via ref.
This commit is contained in:
Bruce Mitchener 2018-11-28 20:12:47 +07:00
parent eea9b79035
commit a3281a02db
2 changed files with 2 additions and 2 deletions

View file

@ -606,7 +606,7 @@ namespace opt {
}
}
void model_based_opt::mk_coeffs_without(vector<var>& dst, vector<var> const src, unsigned x) {
void model_based_opt::mk_coeffs_without(vector<var>& dst, vector<var> const& src, unsigned x) {
for (var const & v : src) {
if (v.m_id != x) dst.push_back(v);
}

View file

@ -132,7 +132,7 @@ namespace opt {
void normalize(unsigned row_id);
void mk_coeffs_without(vector<var>& dst, vector<var> const src, unsigned x);
void mk_coeffs_without(vector<var>& dst, vector<var> const& src, unsigned x);
unsigned new_row();