summaryrefslogtreecommitdiff
path: root/Dafny/Compiler.cs
diff options
context:
space:
mode:
Diffstat (limited to 'Dafny/Compiler.cs')
-rw-r--r--Dafny/Compiler.cs11
1 files changed, 6 insertions, 5 deletions
diff --git a/Dafny/Compiler.cs b/Dafny/Compiler.cs
index 4a2b41a1..caf3df24 100644
--- a/Dafny/Compiler.cs
+++ b/Dafny/Compiler.cs
@@ -545,16 +545,17 @@ namespace Microsoft.Dafny {
Contract.Requires(0 <= indent);
if (expr == null) {
// allow "null" as an argument; nothing to do
- } else if (expr is LetExpr) {
+ return;
+ }
+ if (expr is LetExpr) {
var e = (LetExpr)expr;
foreach (var v in e.Vars) {
Indent(indent);
wr.WriteLine("{0} @{1};", TypeName(v.Type), v.Name);
}
- } else {
- foreach (var ee in expr.SubExpressions) {
- SpillLetVariableDecls(ee, indent);
- }
+ }
+ foreach (var ee in expr.SubExpressions) {
+ SpillLetVariableDecls(ee, indent);
}
}