3
0
Fork 0
mirror of https://github.com/Z3Prover/z3 synced 2025-08-11 05:30:51 +00:00

fix crash in explanation generation. Codeplex issue 181

Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
This commit is contained in:
Nikolaj Bjorner 2015-02-24 17:03:34 -08:00
parent c3232693f0
commit b8fbc32689
4 changed files with 7 additions and 2 deletions

View file

@ -828,11 +828,13 @@ namespace datalog {
SASSERT(&expl_singleton->get_plugin()==m_er_plugin);
m_e_fact_relation = static_cast<explanation_relation *>(expl_singleton);
}
func_decl_set const& predicates = m_context.get_predicates();
func_decl_set predicates(m_context.get_predicates());
decl_set::iterator it = predicates.begin();
decl_set::iterator end = predicates.end();
for (; it!=end; ++it) {
func_decl * orig_decl = *it;
TRACE("dl", tout << mk_pp(orig_decl, m_manager) << "\n";);
func_decl * e_decl = get_e_decl(orig_decl);
if (!rmgr.try_get_relation(orig_decl) &&