mirror of
https://github.com/Z3Prover/z3
synced 2025-08-23 11:37:54 +00:00
ensure also negative lt are constrained
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
This commit is contained in:
parent
1f0d162b7f
commit
85b0722df0
3 changed files with 25 additions and 4 deletions
|
@ -518,6 +518,10 @@ br_status seq_rewriter::mk_app_core(func_decl * f, unsigned num_args, expr * con
|
|||
SASSERT(num_args == 2);
|
||||
st = mk_str_in_regexp(args[0], args[1], result);
|
||||
break;
|
||||
case OP_STRING_LE:
|
||||
SASSERT(num_args == 2);
|
||||
st = mk_str_le(args[0], args[1], result);
|
||||
break;
|
||||
case OP_STRING_CONST:
|
||||
return BR_FAILED;
|
||||
case OP_STRING_ITOS:
|
||||
|
@ -1237,6 +1241,11 @@ br_status seq_rewriter::mk_seq_suffix(expr* a, expr* b, expr_ref& result) {
|
|||
return BR_FAILED;
|
||||
}
|
||||
|
||||
br_status seq_rewriter::mk_str_le(expr* a, expr* b, expr_ref& result) {
|
||||
result = m.mk_not(m_util.str.mk_lex_lt(b, a));
|
||||
return BR_DONE;
|
||||
}
|
||||
|
||||
br_status seq_rewriter::mk_str_itos(expr* a, expr_ref& result) {
|
||||
rational r;
|
||||
if (m_autil.is_numeral(a, r)) {
|
||||
|
|
|
@ -124,6 +124,7 @@ class seq_rewriter {
|
|||
br_status mk_str_stoi(expr* a, expr_ref& result);
|
||||
br_status mk_str_in_regexp(expr* a, expr* b, expr_ref& result);
|
||||
br_status mk_str_to_regexp(expr* a, expr_ref& result);
|
||||
br_status mk_str_le(expr* a, expr* b, expr_ref& result);
|
||||
br_status mk_re_concat(expr* a, expr* b, expr_ref& result);
|
||||
br_status mk_re_union(expr* a, expr* b, expr_ref& result);
|
||||
br_status mk_re_inter(expr* a, expr* b, expr_ref& result);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue