theory THEORY_DATATYPES ::CVC4::theory::datatypes::TheoryDatatypes "theory/datatypes/theory_datatypes.h"
typechecker "theory/datatypes/theory_datatypes_type_rules.h"
-properties check presolve
+properties check presolve parametric
rewriter ::CVC4::theory::datatypes::DatatypesRewriter "theory/datatypes/datatypes_rewriter.h"
}
void Theory::computeCareGraph(CareGraph& careGraph) {
- for (; d_sharedTermsIndex < d_sharedTerms.size(); d_sharedTermsIndex = d_sharedTermsIndex + 1) {
- TNode a = d_sharedTerms[d_sharedTermsIndex];
+ Debug("sharing") << "Theory::computeCareGraph<" << getId() << ">()" << std::endl;
+ for (unsigned i = 0; i < d_sharedTerms.size(); ++ i) {
+ TNode a = d_sharedTerms[i];
TypeNode aType = a.getType();
- for (unsigned i = 0; i < d_sharedTermsIndex; ++ i) {
- TNode b = d_sharedTerms[i];
+ for (unsigned j = i + 1; j < d_sharedTerms.size(); ++ j) {
+ TNode b = d_sharedTerms[j];
if (b.getType() != aType) {
// We don't care about the terms of different types
continue;
// Clear any leftover propagated equalities
d_propagatedEqualities.clear();
- // Mark the lemmas flag (no lemmas added)
- d_lemmasAdded = false;
-
// Mark the output channel unused (if this is FULL_EFFORT, and nothing
// is done by the theories, no additional check will be needed)
d_outputChannelUsed = false;
+ // Mark the lemmas flag (no lemmas added)
+ d_lemmasAdded = false;
+
while (true) {
Debug("theory") << "TheoryEngine::check(" << effort << "): running check" << std::endl;
if (value) {
SharedEquality sharedEquality(toAssert, normalizedEquality, theory::THEORY_LAST, carePair.theory);
- Assert(d_sharedAssertions.find(sharedEquality.toAssert) == d_sharedAssertions.end());
- d_propagatedEqualities.push_back(sharedEquality);
+ if (d_sharedAssertions.find(sharedEquality.toAssert) == d_sharedAssertions.end()) {
+ d_propagatedEqualities.push_back(sharedEquality);
+ }
} else {
SharedEquality sharedEquality(toAssert.notNode(), normalizedEquality.notNode(), theory::THEORY_LAST, carePair.theory);
- Assert(d_sharedAssertions.find(sharedEquality.toAssert) == d_sharedAssertions.end());
- d_propagatedEqualities.push_back(sharedEquality);
+ if (d_sharedAssertions.find(sharedEquality.toAssert) == d_sharedAssertions.end()) {
+ d_propagatedEqualities.push_back(sharedEquality);
+ }
}
} else {
Debug("sharing") << "TheoryEngine::combineTheories(): requesting a split " << std::endl;