summaryrefslogtreecommitdiff
path: root/dhall
diff options
context:
space:
mode:
Diffstat (limited to 'dhall')
-rw-r--r--dhall/src/normalize.rs2
-rw-r--r--dhall/src/typecheck.rs7
2 files changed, 5 insertions, 4 deletions
diff --git a/dhall/src/normalize.rs b/dhall/src/normalize.rs
index 9dd384a..246a3c0 100644
--- a/dhall/src/normalize.rs
+++ b/dhall/src/normalize.rs
@@ -20,7 +20,7 @@ where
{
use dhall_core::BinOp::*;
use dhall_core::Builtin::*;
- use dhall_core::Expr::*;
+ use dhall_core::Expr_::*;
match e {
// Matches that don't normalize everything right away
Let(f, _, r, b) => {
diff --git a/dhall/src/typecheck.rs b/dhall/src/typecheck.rs
index befd8c4..e36a6fa 100644
--- a/dhall/src/typecheck.rs
+++ b/dhall/src/typecheck.rs
@@ -8,7 +8,7 @@ use dhall_core::context::Context;
use dhall_core::core;
use dhall_core::core::Builtin::*;
use dhall_core::core::Const::*;
-use dhall_core::core::Expr::*;
+use dhall_core::core::Expr_::*;
use dhall_core::core::{app, pi};
use dhall_core::core::{bx, shift, subst, Expr, V, X};
@@ -31,7 +31,7 @@ fn rule(a: core::Const, b: core::Const) -> Result<core::Const, ()> {
}
}
-fn match_vars(vl: &V, vr: &V, ctx: &[(&str, &str)]) -> bool {
+fn match_vars(vl: &V<&str>, vr: &V<&str>, ctx: &[(&str, &str)]) -> bool {
let xxs = ctx.get(0).map(|x| (x, ctx.split_at(1).1));
match (vl, vr, xxs) {
(&V(xL, nL), &V(xR, nR), None) => xL == xR && nL == nR,
@@ -186,6 +186,7 @@ where
S: Clone + ::std::fmt::Debug + 'i,
{
use dhall_core::BinOp::*;
+ use dhall_core::Expr_;
match *e {
Const(c) => axiom(c).map(Const), //.map(Cow::Owned),
Var(V(x, n)) => {
@@ -489,7 +490,7 @@ where
Builtin(ListIndexed) => {
let mut m = BTreeMap::new();
m.insert("index", Builtin(Natural));
- m.insert("value", Expr::from("a"));
+ m.insert("value", Expr_::from("a"));
Ok(pi(
"a",
Const(Type),