summaryrefslogtreecommitdiff
path: root/src/theory/quantifiers/term_database.cpp
diff options
context:
space:
mode:
authorAndrew Reynolds <andrew.j.reynolds@gmail.com>2019-08-14 10:37:03 -0500
committerGitHub <noreply@github.com>2019-08-14 10:37:03 -0500
commit4924138b1431d7bbc263bc4a6c63510926da3c72 (patch)
treedf0f434bdd7d5dd048742f0646996c4afa45d399 /src/theory/quantifiers/term_database.cpp
parent5c97514836a18ddb0d00041c013445f2b93efd25 (diff)
Fix issue related to higher-order purification in term database (#3157)
Diffstat (limited to 'src/theory/quantifiers/term_database.cpp')
-rw-r--r--src/theory/quantifiers/term_database.cpp16
1 files changed, 15 insertions, 1 deletions
diff --git a/src/theory/quantifiers/term_database.cpp b/src/theory/quantifiers/term_database.cpp
index 989609a76..84147bf6b 100644
--- a/src/theory/quantifiers/term_database.cpp
+++ b/src/theory/quantifiers/term_database.cpp
@@ -1039,7 +1039,21 @@ bool TermDb::reset( Theory::Effort effort ){
}
Trace("quant-ho") << "- assert purify equality : " << eq << std::endl;
ee->assertEquality(eq, true, eq);
- Assert(ee->consistent());
+ if (!ee->consistent())
+ {
+ // In some rare cases, purification functions (in the domain of
+ // d_ho_purify_to_term) may escape the term database. For example,
+ // matching algorithms may construct instantiations involving these
+ // functions. As a result, asserting these equalities internally may
+ // cause a conflict. In this case, we insist that the purification
+ // equality is sent out as a lemma here.
+ Trace("term-db-lemma")
+ << "Purify equality lemma: " << eq << std::endl;
+ d_quantEngine->addLemma(eq);
+ d_quantEngine->setConflict();
+ d_consistent_ee = false;
+ return false;
+ }
}
}
}
generated by cgit on debian on lair
contact matthew@masot.net with questions or feedback