summaryrefslogtreecommitdiff
path: root/Source/Dafny/Printer.cs
diff options
context:
space:
mode:
authorGravatar leino <unknown>2014-08-26 05:33:22 -0700
committerGravatar leino <unknown>2014-08-26 05:33:22 -0700
commitf7d1a3200a18cb15bc49f6d89068ddd1e99efe0e (patch)
tree9b0e37e601cb9534093b104d0d686b9931b5b825 /Source/Dafny/Printer.cs
parent1d0b11b6fad56619741fe019d8cc8ca4085654b4 (diff)
Changed syntax of newtype
Diffstat (limited to 'Source/Dafny/Printer.cs')
-rw-r--r--Source/Dafny/Printer.cs9
1 files changed, 6 insertions, 3 deletions
diff --git a/Source/Dafny/Printer.cs b/Source/Dafny/Printer.cs
index 316116e7..516eeade 100644
--- a/Source/Dafny/Printer.cs
+++ b/Source/Dafny/Printer.cs
@@ -149,9 +149,12 @@ namespace Microsoft.Dafny {
if (dd.Var == null) {
PrintType(dd.BaseType);
} else {
- wr.Write("{0}: ", dd.Var.DisplayName);
- PrintType(dd.BaseType);
- wr.Write(" where ");
+ wr.Write(dd.Var.DisplayName);
+ if (!(dd.Var.Type is TypeProxy) || DafnyOptions.O.DafnyPrintResolvedFile != null) {
+ wr.Write(": ");
+ PrintType(dd.BaseType);
+ }
+ wr.Write(" | ");
PrintExpression(dd.Constraint, true);
}
wr.WriteLine();