diff options
author | Jason Koenig <unknown> | 2012-07-17 18:27:03 -0700 |
---|---|---|
committer | Jason Koenig <unknown> | 2012-07-17 18:27:03 -0700 |
commit | b76f8a0e1a7174b266aa64f82b08631a2efa5d10 (patch) | |
tree | 6e99a6c38ca4c9485282170d876dd6ecf62ad82d /Dafny/Resolver.cs | |
parent | 590079fd7a28692b67fe98c6bb2ab0bc915254c3 (diff) |
Dafny: allowed strictly finite datatypes in comprehensions, quantifiers, and parallel statements.
Diffstat (limited to 'Dafny/Resolver.cs')
-rw-r--r-- | Dafny/Resolver.cs | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/Dafny/Resolver.cs b/Dafny/Resolver.cs index 74ddb08b..8c14cb0c 100644 --- a/Dafny/Resolver.cs +++ b/Dafny/Resolver.cs @@ -4946,6 +4946,8 @@ namespace Microsoft.Dafny if (bv.Type is BoolType) {
// easy
bounds.Add(new QuantifierExpr.BoolBoundedPool());
+ } else if (bv.Type.IsIndDatatype && (bv.Type.AsIndDatatype).HasFinitePossibleValues) {
+ bounds.Add(new QuantifierExpr.DatatypeBoundedPool(bv.Type.AsIndDatatype));
} else {
// Go through the conjuncts of the range expression to look for bounds.
Expression lowerBound = bv.Type is NatType ? new LiteralExpr(bv.tok, new BigInteger(0)) : null;
|