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

revert normalizing ordering on equality as it breaks others and doesn't necessarily lead to simplification

Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
This commit is contained in:
Nikolaj Bjorner 2019-06-22 23:48:00 +02:00
parent 5dfc40bf50
commit 2a1f8ac2d8
2 changed files with 6 additions and 4 deletions

View file

@ -645,6 +645,11 @@ br_status bool_rewriter::try_ite_value(app * ite, app * val, expr_ref & result)
}
app* bool_rewriter::mk_eq(expr* lhs, expr* rhs) {
// if (lhs->get_id() > rhs->get_id()) std::swap(lhs, rhs);
return m().mk_eq(lhs, rhs);
}
br_status bool_rewriter::mk_eq_core(expr * lhs, expr * rhs, expr_ref & result) {
if (m().are_equal(lhs, rhs)) {
result = m().mk_true();

View file

@ -127,10 +127,7 @@ public:
br_status mk_ite_core(expr * c, expr * t, expr * e, expr_ref & result);
br_status mk_not_core(expr * t, expr_ref & result);
app* mk_eq(expr* lhs, expr* rhs) {
if (lhs->get_id() > rhs->get_id()) std::swap(lhs, rhs);
return m().mk_eq(lhs, rhs);
}
app* mk_eq(expr* lhs, expr* rhs);
void mk_eq(expr * lhs, expr * rhs, expr_ref & result) {
if (mk_eq_core(lhs, rhs, result) == BR_FAILED)