diff options
author | ajreynol <andrew.j.reynolds@gmail.com> | 2016-12-01 10:47:31 -0600 |
---|---|---|
committer | ajreynol <andrew.j.reynolds@gmail.com> | 2016-12-01 10:47:47 -0600 |
commit | ffaf556b34e3ef2972b47caea00b7da149aeea8f (patch) | |
tree | 0fd3616edf9aed8447bce1ffaa5e444d8824e43c /test | |
parent | 154002c3a1b07ead16cfcac05a7580abc424e472 (diff) |
Improvement and bug fix for str.indexof reduction, add regression. Other minor changes.
Diffstat (limited to 'test')
-rw-r--r-- | test/regress/regress0/strings/Makefile.am | 3 | ||||
-rw-r--r-- | test/regress/regress0/strings/strings-index-empty.smt2 | 11 |
2 files changed, 13 insertions, 1 deletions
diff --git a/test/regress/regress0/strings/Makefile.am b/test/regress/regress0/strings/Makefile.am index 21d51199d..70fec7b82 100644 --- a/test/regress/regress0/strings/Makefile.am +++ b/test/regress/regress0/strings/Makefile.am @@ -83,7 +83,8 @@ TESTS = \ csp-prefix-exp-bug.smt2 \ cmu-substr-rw.smt2 \ gm-inc-071516-2.smt2 \ - cmu-inc-nlpp-071516.smt2 + cmu-inc-nlpp-071516.smt2 \ + strings-index-empty.smt2 FAILING_TESTS = diff --git a/test/regress/regress0/strings/strings-index-empty.smt2 b/test/regress/regress0/strings/strings-index-empty.smt2 new file mode 100644 index 000000000..a726d9cab --- /dev/null +++ b/test/regress/regress0/strings/strings-index-empty.smt2 @@ -0,0 +1,11 @@ +; COMMAND-LINE: --simplification=none --strings-exp --no-strings-lazy-pp +; EXPECT: sat +(set-logic SLIA) +(set-info :status sat) +(declare-fun x () String) +(declare-fun f () String) +(declare-fun y () Int) +(assert (= (str.len f) 0)) +; command line options ensure reduction is invoked for indexof, f is "", should return -1 +(assert (= (str.indexof x f 4) y)) +(check-sat) |