diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/options/strings_options.toml | 9 | ||||
-rw-r--r-- | src/theory/strings/term_registry.cpp | 15 |
2 files changed, 7 insertions, 17 deletions
diff --git a/src/options/strings_options.toml b/src/options/strings_options.toml index 3cf8f5852..32c4c64c7 100644 --- a/src/options/strings_options.toml +++ b/src/options/strings_options.toml @@ -55,15 +55,6 @@ header = "options/strings_options.h" help = "perform string preprocessing lazily" [[option]] - name = "stringLenGeqZ" - category = "regular" - long = "strings-len-geqz" - type = "bool" - default = "false" - read_only = true - help = "strings length greater than zero lemmas" - -[[option]] name = "stringLenNorm" category = "regular" long = "strings-len-norm" diff --git a/src/theory/strings/term_registry.cpp b/src/theory/strings/term_registry.cpp index ec034b0c9..6330d7c10 100644 --- a/src/theory/strings/term_registry.cpp +++ b/src/theory/strings/term_registry.cpp @@ -374,6 +374,13 @@ Node TermRegistry::getRegisterTermAtomicLemma(Node n, LengthStatus s, std::map<Node, bool>& reqPhase) { + if (n.isConst()) + { + // No need to send length for constant terms. This case may be triggered + // for cases where the skolem cache automatically replaces a skolem by + // a constant. + return Node::null(); + } Assert(n.getType().isStringLike()); NodeManager* nm = NodeManager::currentNM(); Node n_len = nm->mkNode(kind::STRING_LENGTH, n); @@ -433,14 +440,6 @@ Node TermRegistry::getRegisterTermAtomicLemma(Node n, Assert(false); } - // additionally add len( x ) >= 0 ? - if (options::stringLenGeqZ()) - { - Node n_len_geq = nm->mkNode(kind::GEQ, n_len, d_zero); - n_len_geq = Rewriter::rewrite(n_len_geq); - lems.push_back(n_len_geq); - } - if (lems.empty()) { return Node::null(); |