summaryrefslogtreecommitdiff
path: root/dhall/src/expr.rs
diff options
context:
space:
mode:
authorNadrieril2019-04-11 15:25:04 +0200
committerNadrieril2019-04-11 15:25:04 +0200
commitb694e567392256eb0a429586b2230253d4d80564 (patch)
tree83afeaf6da32ef86af0afdfc8b4ed224a442dd67 /dhall/src/expr.rs
parent36a6f9a09b966922baf4838599e57250982b0fc3 (diff)
Improve simple type handling in typecheck
Diffstat (limited to '')
-rw-r--r--dhall/src/expr.rs5
1 files changed, 5 insertions, 0 deletions
diff --git a/dhall/src/expr.rs b/dhall/src/expr.rs
index 6458be9..30ca6c6 100644
--- a/dhall/src/expr.rs
+++ b/dhall/src/expr.rs
@@ -88,3 +88,8 @@ impl Normalized {
}
}
+impl SimpleType {
+ pub(crate) fn into_type(self) -> Type {
+ Normalized(self.0, Some(Type::const_type())).into_type()
+ }
+}