mirror of
https://github.com/Z3Prover/z3
synced 2025-08-23 03:27:52 +00:00
Regex membership (#7506)
* Make finding a word in the regex iterative * Fixed gc problem
This commit is contained in:
parent
9a237d55ca
commit
c572fc2e4f
5 changed files with 103 additions and 169 deletions
|
@ -883,10 +883,13 @@ public:
|
|||
case OP_SEQ_IN_RE:
|
||||
if (uncnstr(args[0]) && seq.re.is_ground(args[1]) && seq.is_string(args[0]->get_sort())) {
|
||||
#if 1
|
||||
zstring s1, s2;
|
||||
zstring s1;
|
||||
expr* re = args[1];
|
||||
if (!rw.some_string_in_re(re, s1))
|
||||
return false;
|
||||
zstring s2;
|
||||
expr_ref not_re(seq.re.mk_complement(re), m);
|
||||
if (!rw.some_string_in_re(re, s1) || !rw.some_string_in_re(not_re, s2))
|
||||
if (!rw.some_string_in_re(not_re, s2))
|
||||
return false;
|
||||
|
||||
mk_fresh_uncnstr_var_for(f, r);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue