From 929a34c177f8b18ae791f77bbd4630a862fb1070 Mon Sep 17 00:00:00 2001 From: Nadrieril Date: Sun, 15 Dec 2019 19:42:57 +0000 Subject: Reexport dhall_syntax as a module in dhall --- dhall/src/core/context.rs | 2 +- dhall/src/core/value.rs | 2 +- dhall/src/core/valuef.rs | 4 ++-- dhall/src/core/var.rs | 10 +++++----- 4 files changed, 9 insertions(+), 9 deletions(-) (limited to 'dhall/src/core') diff --git a/dhall/src/core/context.rs b/dhall/src/core/context.rs index 2bf39c5..00e1493 100644 --- a/dhall/src/core/context.rs +++ b/dhall/src/core/context.rs @@ -1,7 +1,7 @@ use std::collections::HashMap; use std::rc::Rc; -use dhall_syntax::{Label, V}; +use crate::syntax::{Label, V}; use crate::core::value::Value; use crate::core::valuef::ValueF; diff --git a/dhall/src/core/value.rs b/dhall/src/core/value.rs index d4f5131..bd7a9b9 100644 --- a/dhall/src/core/value.rs +++ b/dhall/src/core/value.rs @@ -1,7 +1,7 @@ use std::cell::{Ref, RefCell, RefMut}; use std::rc::Rc; -use dhall_syntax::{Builtin, Const, Span}; +use crate::syntax::{Builtin, Const, Span}; use crate::core::context::TypecheckContext; use crate::core::valuef::ValueF; diff --git a/dhall/src/core/valuef.rs b/dhall/src/core/valuef.rs index e5d0807..e9ac391 100644 --- a/dhall/src/core/valuef.rs +++ b/dhall/src/core/valuef.rs @@ -1,6 +1,6 @@ use std::collections::HashMap; -use dhall_syntax::{ +use crate::syntax::{ Builtin, Const, ExprF, Integer, InterpolatedTextContents, Label, NaiveDouble, Natural, }; @@ -117,7 +117,7 @@ impl ValueF { .collect(), )), ValueF::Equivalence(x, y) => rc(ExprF::BinOp( - dhall_syntax::BinOp::Equivalence, + crate::syntax::BinOp::Equivalence, x.to_expr(opts), y.to_expr(opts), )), diff --git a/dhall/src/core/var.rs b/dhall/src/core/var.rs index 3795f10..f9d3478 100644 --- a/dhall/src/core/var.rs +++ b/dhall/src/core/var.rs @@ -1,6 +1,6 @@ use std::collections::HashMap; -use dhall_syntax::{Label, V}; +use crate::syntax::{Label, V}; /// Stores a pair of variables: a normal one and one /// that corresponds to the alpha-normalized version of the first one. @@ -190,7 +190,7 @@ impl Shift for std::cell::RefCell { } } -impl Shift for dhall_syntax::ExprF { +impl Shift for crate::syntax::ExprF { fn shift(&self, delta: isize, var: &AlphaVar) -> Option { Some(self.traverse_ref_with_special_handling_of_binders( |v| Ok(v.shift(delta, var)?), @@ -222,7 +222,7 @@ where } } -impl Shift for dhall_syntax::InterpolatedTextContents { +impl Shift for crate::syntax::InterpolatedTextContents { fn shift(&self, delta: isize, var: &AlphaVar) -> Option { Some(self.traverse_ref(|x| Ok(x.shift(delta, var)?))?) } @@ -262,7 +262,7 @@ impl> Subst for std::cell::RefCell { } } -impl, E: Clone> Subst for dhall_syntax::ExprF { +impl, E: Clone> Subst for crate::syntax::ExprF { fn subst_shift(&self, var: &AlphaVar, val: &S) -> Self { self.map_ref_with_special_handling_of_binders( |v| v.subst_shift(var, val), @@ -277,7 +277,7 @@ impl> Subst for Vec { } } -impl> Subst for dhall_syntax::InterpolatedTextContents { +impl> Subst for crate::syntax::InterpolatedTextContents { fn subst_shift(&self, var: &AlphaVar, val: &S) -> Self { self.map_ref(|x| x.subst_shift(var, val)) } -- cgit v1.2.3