summaryrefslogtreecommitdiff
path: root/dhall_core/src/printer.rs
diff options
context:
space:
mode:
authorNadrieril2019-03-23 23:24:11 +0100
committerNadrieril2019-03-23 23:24:11 +0100
commit062fc44a93a18ee432e51db852290ab5849f4dd9 (patch)
treec9dd53daf9cd99f5dcf982e1d98099a078f63110 /dhall_core/src/printer.rs
parentf610bc0aac5eaa365c95b489fb2d06cab449ec77 (diff)
Handle merge and record projection
Diffstat (limited to '')
-rw-r--r--dhall_core/src/printer.rs5
1 files changed, 5 insertions, 0 deletions
diff --git a/dhall_core/src/printer.rs b/dhall_core/src/printer.rs
index 5ecf5ce..d93336e 100644
--- a/dhall_core/src/printer.rs
+++ b/dhall_core/src/printer.rs
@@ -165,6 +165,11 @@ impl<S, A: Display> Expr<S, A> {
a.fmt_e(f)?;
write!(f, ".{}", b)
}
+ &Projection(ref e, ref ls) => {
+ e.fmt_e(f)?;
+ write!(f, ".")?;
+ fmt_list("{ ", ", ", " }", ls, f, |l, f| write!(f, "{}", l))
+ }
&Note(_, ref b) => b.fmt_e(f),
a => a.fmt_f(f),
}