summaryrefslogtreecommitdiff
path: root/dhall/src/core/thunk.rs
diff options
context:
space:
mode:
authorNadrieril2019-05-08 18:02:30 +0200
committerNadrieril2019-05-08 18:02:30 +0200
commit8a47d27ccc1c800615cc721e01816fda7df68b01 (patch)
tree9b7ad0bbcb1b6bf2f42a6c5a8ee23dcde53f66f6 /dhall/src/core/thunk.rs
parent7aafedae36fe81a64720592f75723b6646913fe2 (diff)
Implement normalization for record merging operators
Diffstat (limited to 'dhall/src/core/thunk.rs')
-rw-r--r--dhall/src/core/thunk.rs7
1 files changed, 7 insertions, 0 deletions
diff --git a/dhall/src/core/thunk.rs b/dhall/src/core/thunk.rs
index 530762b..a02d7ae 100644
--- a/dhall/src/core/thunk.rs
+++ b/dhall/src/core/thunk.rs
@@ -235,6 +235,13 @@ impl TypeThunk {
}
}
+ pub(crate) fn to_thunk(&self) -> Thunk {
+ match self {
+ TypeThunk::Thunk(th) => th.clone(),
+ TypeThunk::Type(t) => t.to_thunk(),
+ }
+ }
+
pub(crate) fn to_type(
&self,
ctx: &TypecheckContext,