X-Git-Url: http://git.megacz.com/?p=coq-hetmet.git;a=blobdiff_plain;f=src%2FHaskProof.v;h=64746651808aab81c04759c3602f3f845936b742;hp=7ae3462877aafbb9115538ab0fb9f5ecedd29d2b;hb=2ec43bc871b579bac89707988c4855ee1d6c8eda;hpb=8c26722a1ee110077968a8a166eb7130266b2035 diff --git a/src/HaskProof.v b/src/HaskProof.v index 7ae3462..6474665 100644 --- a/src/HaskProof.v +++ b/src/HaskProof.v @@ -14,7 +14,7 @@ Require Import Coq.Strings.String. Require Import Coq.Lists.List. Require Import HaskKinds. Require Import HaskCoreTypes. -Require Import HaskCoreLiterals. +Require Import HaskLiteralsAndTyCons. Require Import HaskStrongTypes. (* A judgment consists of an environment shape (Γ and Δ) and a pair of trees of leveled types (the antecedent and succedent) valid @@ -40,8 +40,8 @@ Inductive UJudg (Γ:TypeEnv)(Δ:CoercionEnv Γ) := Tree ??(LeveledHaskType Γ ★) -> UJudg Γ Δ. Notation "Γ >> Δ > a '|-' s" := (mkUJudg Γ Δ a s) (at level 52, Δ at level 50, a at level 52, s at level 50). - Notation "'ext_tree_left'" := (fun ctx j => match j with mkUJudg t s => mkUJudg _ _ (ctx,,t) s end). - Notation "'ext_tree_right'" := (fun ctx j => match j with mkUJudg t s => mkUJudg _ _ (t,,ctx) s end). + Definition ext_tree_left {Γ}{Δ} := (fun ctx (j:UJudg Γ Δ) => match j with mkUJudg t s => mkUJudg Γ Δ (ctx,,t) s end). + Definition ext_tree_right {Γ}{Δ} := (fun ctx (j:UJudg Γ Δ) => match j with mkUJudg t s => mkUJudg Γ Δ (t,,ctx) s end). (* we can turn a UJudg into a Judg by simply internalizing the index *) Definition UJudg2judg {Γ}{Δ}(ej:@UJudg Γ Δ) : Judg :=