3
0
Fork 0
mirror of https://github.com/Z3Prover/z3 synced 2025-04-06 17:44:08 +00:00
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
This commit is contained in:
Nikolaj Bjorner 2019-05-31 16:22:49 -07:00
parent dd452e0ac1
commit 01f6489892

View file

@ -190,11 +190,21 @@ void rule_properties::operator()(app* n) {
sort* s = m.get_sort(n->get_arg(0));
SASSERT(m_dt.is_datatype(s));
if (m_dt.get_datatype_constructors(s)->size() > 1) {
m_uninterp_funs.insert(n->get_decl(), m_rule);
bool found = false;
func_decl * c = m_dt.get_accessor_constructor(n->get_decl());
unsigned ut_size = m_rule->get_uninterpreted_tail_size();
unsigned t_size = m_rule->get_tail_size();
for (unsigned i = ut_size; !found && i < t_size; ++i) {
app* t = m_rule->get_tail(i);
if (m_dt.is_recognizer(t) && t->get_arg(0) == n->get_arg(0) && m_dt.get_recognizer_constructor(t->get_decl()) == c) {
found = true;
}
}
if (!found) {
m_uninterp_funs.insert(n->get_decl(), m_rule);
}
}
}
else {
}
}