diff options
author | MichalMoskal <unknown> | 2011-02-23 22:48:50 +0000 |
---|---|---|
committer | MichalMoskal <unknown> | 2011-02-23 22:48:50 +0000 |
commit | f65685831ad6852cdc051f0e5482544697f7ca9f (patch) | |
tree | a50917d9c7d78f72b83a0effae69b6f8433a87bb | |
parent | 408127c0fb6f2d38ce41d5e838777b7df36df438 (diff) |
Don't ever put a label under a quantifier.
-rw-r--r-- | Source/Provers/SMTLib/SMTLibLineariser.cs | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/Source/Provers/SMTLib/SMTLibLineariser.cs b/Source/Provers/SMTLib/SMTLibLineariser.cs index 35c4d5f0..a2d6952c 100644 --- a/Source/Provers/SMTLib/SMTLibLineariser.cs +++ b/Source/Provers/SMTLib/SMTLibLineariser.cs @@ -70,6 +70,7 @@ namespace Microsoft.Boogie.SMTLib }
internal readonly UniqueNamer Namer;
+ internal int UnderQuantifier = 0;
internal readonly SMTLibProverOptions ProverOptions;
public SMTLibExprLineariser(TextWriter wr, UniqueNamer namer, SMTLibProverOptions opts)
@@ -231,6 +232,7 @@ namespace Microsoft.Boogie.SMTLib {
Contract.Assert(node.TypeParameters.Count == 0);
+ UnderQuantifier++;
Namer.PushScope(); try {
string kind = node.Quan == Quantifier.ALL ? "forall" : "exists";
@@ -275,6 +277,7 @@ namespace Microsoft.Boogie.SMTLib return true;
} finally {
+ UnderQuantifier--;
Namer.PopScope();
}
}
@@ -505,6 +508,11 @@ namespace Microsoft.Boogie.SMTLib public bool VisitLabelOp(VCExprNAry node, LineariserOptions options)
{
+ if (ExprLineariser.UnderQuantifier > 0) {
+ ExprLineariser.Linearise(node[0], options);
+ return true;
+ }
+
var op = (VCExprLabelOp)node.Op;
if (ExprLineariser.ProverOptions.UseLabels) {
// Z3 extension
|