mirror of
https://github.com/Z3Prover/z3
synced 2025-08-03 18:00:23 +00:00
fix axiomatization of str.replace. Fixes issue #703
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
This commit is contained in:
parent
2d8325ed43
commit
879f792125
2 changed files with 7 additions and 2 deletions
|
@ -2903,10 +2903,12 @@ void theory_seq::add_replace_axiom(expr* r) {
|
|||
expr_ref xsy = mk_concat(x, s, y);
|
||||
literal cnt = mk_literal(m_util.str.mk_contains(a ,s));
|
||||
literal a_emp = mk_eq_empty(a);
|
||||
literal s_emp = mk_eq_empty(s);
|
||||
add_axiom(~a_emp, mk_seq_eq(r, a));
|
||||
add_axiom(cnt, mk_seq_eq(r, a));
|
||||
add_axiom(~cnt, a_emp, mk_seq_eq(a, xsy));
|
||||
add_axiom(~cnt, a_emp, mk_seq_eq(r, xty));
|
||||
add_axiom(~s_emp, mk_seq_eq(r, a));
|
||||
add_axiom(~cnt, a_emp, s_emp, mk_seq_eq(a, xsy));
|
||||
add_axiom(~cnt, a_emp, s_emp, mk_seq_eq(r, xty));
|
||||
tightest_prefix(s, x);
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue