// is it an equivalence class with a seq.unit term?
if (nfe.d_nf[0].getKind() == SEQ_UNIT)
{
- pure_eq_assign[eqc] = nfe.d_nf[0];
+ Node c = Rewriter::rewrite(nm->mkNode(
+ SEQ_UNIT, d_valuation.getModelValue(nfe.d_nf[0][0])));
+ pure_eq_assign[eqc] = c;
Trace("strings-model") << "(unit: " << nfe.d_nf[0] << ") ";
+ m->getEqualityEngine()->addTerm(c);
}
// does it have a code and the length of these equivalence classes are
// one?
else
{
processed[eqc] = eqc;
+ // Make sure that constants are asserted to the theory model that we
+ // are building. It is possible that new constants were introduced by
+ // the eager evaluation in the equality engine. These terms are missing
+ // in the term set and, as a result, are skipped when the equality
+ // engine is asserted to the theory model.
+ m->getEqualityEngine()->addTerm(eqc);
}
}
Trace("strings-model") << "have length " << lts_values[i] << std::endl;
regress1/strings/issue4735.smt2
regress1/strings/issue4735_2.smt2
regress1/strings/issue4759-comp-delta.smt2
+ regress1/strings/issue5330.smt2
+ regress1/strings/issue5330_2.smt2
regress1/strings/issue5374-proxy-i.smt2
regress1/strings/kaluza-fl.smt2
regress1/strings/loop002.smt2
--- /dev/null
+; COMMAND-LINE: --strings-exp
+; EXPECT: sat
+(set-logic QF_SLIA)
+(declare-fun str1 () String)
+(declare-fun str18 () String)
+(assert (str.in_re (str.replace str18 str1 str18) (str.to_re "pANjvthXNyBbIgIlkC")))
+(check-sat)
--- /dev/null
+; COMMAND-LINE: --strings-exp
+; EXPECT: sat
+(set-logic QF_SLIA)
+(declare-fun seq11 () (Seq Int))
+(declare-fun i5 () Int)
+(declare-fun v17 () Bool)
+(declare-fun v24 () Bool)
+(assert (xor v17 v24 true true (seq.prefixof (seq.rev (seq.rev seq11)) (seq.unit i5))))
+(check-sat)