summaryrefslogtreecommitdiff
path: root/dhall/src/traits
diff options
context:
space:
mode:
authorNadrieril2019-04-29 16:34:13 +0200
committerNadrieril2019-04-29 16:34:13 +0200
commit5a3d63ecb46ee0b4ab3a7b49cf9feb286b164803 (patch)
tree44a4919a63a0fc08be68c47f47c39ca09fbf5648 /dhall/src/traits
parent5c16a75c6dc01bbd0bfe36be4a9b337a762632a8 (diff)
Don't need to store original expression in TypeError
Diffstat (limited to '')
-rw-r--r--dhall/src/traits/dynamic_type.rs11
1 files changed, 0 insertions, 11 deletions
diff --git a/dhall/src/traits/dynamic_type.rs b/dhall/src/traits/dynamic_type.rs
index f783950..c15b277 100644
--- a/dhall/src/traits/dynamic_type.rs
+++ b/dhall/src/traits/dynamic_type.rs
@@ -23,15 +23,6 @@ impl<'a> DynamicType for Type<'a> {
Ok(Cow::Owned(
self.clone().into_normalized()?.get_type()?.into_owned(),
))
- // match &self.0 {
- // TypeInternal::Expr(e) => e.get_type(),
- // TypeInternal::Const(c) => Ok(Cow::Owned(type_of_const(*c))),
- // TypeInternal::SuperType => Err(TypeError::new(
- // &TypecheckContext::new(),
- // dhall_core::rc(ExprF::Const(Const::Sort)),
- // TypeMessage::Untyped,
- // )),
- // }
}
}
@@ -41,7 +32,6 @@ impl<'a> DynamicType for Normalized<'a> {
Some(t) => Ok(Cow::Borrowed(t)),
None => Err(TypeError::new(
&TypecheckContext::new(),
- self.0.embed_absurd(),
TypeMessage::Untyped,
)),
}
@@ -54,7 +44,6 @@ impl<'a> DynamicType for Typed<'a> {
Some(t) => Ok(Cow::Borrowed(t)),
None => Err(TypeError::new(
&TypecheckContext::new(),
- self.0.clone(),
TypeMessage::Untyped,
)),
}