diff options
author | Rustan Leino <leino@microsoft.com> | 2013-05-21 16:09:12 -0700 |
---|---|---|
committer | Rustan Leino <leino@microsoft.com> | 2013-05-21 16:09:12 -0700 |
commit | 196cba780116c93e4c39afa85defefa28d13bd3f (patch) | |
tree | c715ccde3dcb1554d1dfa65f2ab92f956eda72ed | |
parent | 2fa6ad2a4dbf072afd0b99e35c3dc5defedb0ad0 (diff) |
Fixed bug, where prefix predicate was not included in CheckTypeInference visitor
-rw-r--r-- | Source/Dafny/Resolver.cs | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/Source/Dafny/Resolver.cs b/Source/Dafny/Resolver.cs index 738aa71c..9b7e1a98 100644 --- a/Source/Dafny/Resolver.cs +++ b/Source/Dafny/Resolver.cs @@ -1541,6 +1541,7 @@ namespace Microsoft.Dafny }
} else if (member is Function) {
var f = (Function)member;
+ var errorCount = ErrorCount;
f.Req.Iter(CheckTypeInference);
f.Ens.Iter(CheckTypeInference);
f.Reads.Iter(fe => CheckTypeInference(fe.E));
@@ -1552,6 +1553,10 @@ namespace Microsoft.Dafny Error(f.tok, "sorry, tail-call functions are not supported");
}
}
+ if (errorCount == ErrorCount && f is CoPredicate) {
+ var cop = (CoPredicate)f;
+ CheckTypeInference_Member(cop.PrefixPredicate);
+ }
}
}
void CheckTypeInference(Expression expr) {
|