diff options
author | Andrew Reynolds <andrew.j.reynolds@gmail.com> | 2021-04-12 16:55:44 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-04-12 21:55:44 +0000 |
commit | 76f495646c0e3a95f2474c5d746bc61ece18f89f (patch) | |
tree | 5390007f4be229dfb18e641f34b9d9df6a9dea92 /src/theory/quantifiers/sygus | |
parent | af398235ef9f3a909991fddbb71d43434d6cf3a1 (diff) |
Fix computation of whether a type is finite (#6312)
This PR generalizes TypeNode::isFinite / TypeNode::isInterpretedFinite with TypeNode::getCardinalityClass. It then uses this method to fix our computation of when a type should be treated as finite.
Fixes #4260, fixes #6100 (that benchmark now says unknown without an error).
Diffstat (limited to 'src/theory/quantifiers/sygus')
-rw-r--r-- | src/theory/quantifiers/sygus/sygus_enumerator.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/theory/quantifiers/sygus/sygus_enumerator.cpp b/src/theory/quantifiers/sygus/sygus_enumerator.cpp index c0fb17dab..83a4276ab 100644 --- a/src/theory/quantifiers/sygus/sygus_enumerator.cpp +++ b/src/theory/quantifiers/sygus/sygus_enumerator.cpp @@ -773,8 +773,10 @@ bool SygusEnumerator::TermEnumMaster::incrementInternal() // have we run out of constructor classes for this size? if (d_ccCons.empty()) { - // check whether we should terminate - if (d_tn.isInterpretedFinite()) + // check whether we should terminate, which notice always treats + // uninterpreted sorts as infinite, since we do not put bounds on them + // in our enumeration. + if (isCardinalityClassFinite(d_tn.getCardinalityClass(), false)) { if (ncc == tc.getNumConstructorClasses()) { |