diff options
author | Nadrieril | 2020-04-06 22:24:15 +0100 |
---|---|---|
committer | Nadrieril | 2020-04-06 22:26:08 +0100 |
commit | 56efd2ac39149d8652bd625fbf0679c10823b137 (patch) | |
tree | 4d9e58ad86ea37dca7a2232ab475791669000684 /dhall/src/semantics/tck | |
parent | 2cf9169e1a21e1196e0265847abcfa904e2d45a3 (diff) |
Move BinOp and Builtin definitions in the relevant module
Diffstat (limited to 'dhall/src/semantics/tck')
-rw-r--r-- | dhall/src/semantics/tck/tir.rs | 3 | ||||
-rw-r--r-- | dhall/src/semantics/tck/typecheck.rs | 6 |
2 files changed, 4 insertions, 5 deletions
diff --git a/dhall/src/semantics/tck/tir.rs b/dhall/src/semantics/tck/tir.rs index 89a8027..ec15a1f 100644 --- a/dhall/src/semantics/tck/tir.rs +++ b/dhall/src/semantics/tck/tir.rs @@ -1,6 +1,7 @@ +use crate::builtins::Builtin; use crate::error::{ErrorBuilder, TypeError}; use crate::semantics::{mkerr, Hir, Nir, NirKind, NzEnv, TyEnv, VarEnv}; -use crate::syntax::{Builtin, Const, Expr, Span}; +use crate::syntax::{Const, Expr, Span}; /// The type of a type. 0 is `Type`, 1 is `Kind`, etc... #[derive(Debug, Copy, Clone, PartialEq, Eq, PartialOrd, Ord, Default)] diff --git a/dhall/src/semantics/tck/typecheck.rs b/dhall/src/semantics/tck/typecheck.rs index a31f15c..c6300d9 100644 --- a/dhall/src/semantics/tck/typecheck.rs +++ b/dhall/src/semantics/tck/typecheck.rs @@ -1,13 +1,11 @@ use std::cmp::max; use std::collections::HashMap; -use crate::builtins::type_of_builtin; +use crate::builtins::{type_of_builtin, Builtin}; use crate::error::{ErrorBuilder, TypeError, TypeMessage}; use crate::operations::typecheck_operation; use crate::semantics::{Hir, HirKind, Nir, NirKind, Tir, TyEnv, Type}; -use crate::syntax::{ - Builtin, Const, ExprKind, InterpolatedTextContents, NumKind, Span, -}; +use crate::syntax::{Const, ExprKind, InterpolatedTextContents, NumKind, Span}; fn function_check(a: Const, b: Const) -> Const { if b == Const::Type { |