mirror of
https://github.com/Z3Prover/z3
synced 2026-02-22 16:27:37 +00:00
Refactor SMT core: use structured bindings for enode_pair access (#8427)
* Initial plan * Refactor SMT core to use C++17 structured bindings for enode pairs Co-authored-by: NikolajBjorner <3085284+NikolajBjorner@users.noreply.github.com> * Use const& in structured bindings to avoid copying Co-authored-by: NikolajBjorner <3085284+NikolajBjorner@users.noreply.github.com> * Refactor variable unpacking in DEBUG_CODE --------- Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: NikolajBjorner <3085284+NikolajBjorner@users.noreply.github.com> Co-authored-by: Nikolaj Bjorner <nbjorner@microsoft.com>
This commit is contained in:
parent
3c34c5c4d7
commit
78381bb285
4 changed files with 16 additions and 14 deletions
|
|
@ -487,8 +487,8 @@ namespace smt {
|
|||
fmls.push_back(n);
|
||||
}
|
||||
for (unsigned i = 0; i < num_eq_antecedents; ++i) {
|
||||
enode_pair const & p = eq_antecedents[i];
|
||||
n = m.mk_eq(p.first->get_expr(), p.second->get_expr());
|
||||
auto const& [n1, n2] = eq_antecedents[i];
|
||||
n = m.mk_eq(n1->get_expr(), n2->get_expr());
|
||||
fmls.push_back(n);
|
||||
}
|
||||
if (x && y) {
|
||||
|
|
@ -697,7 +697,8 @@ namespace smt {
|
|||
}
|
||||
|
||||
std::ostream& operator<<(std::ostream& out, enode_eq_pp const& p) {
|
||||
return out << enode_pp(p.p.first, p.ctx) << " = " << enode_pp(p.p.second, p.ctx) << "\n";
|
||||
auto const& [n1, n2] = p.p;
|
||||
return out << enode_pp(n1, p.ctx) << " = " << enode_pp(n2, p.ctx) << "\n";
|
||||
}
|
||||
|
||||
void context::log_stats() {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue