Fix the typing rules

This commit is contained in:
Yiyun Liu 2025-03-03 01:38:22 -05:00
parent 47e21df801
commit b3bd75ad42
3 changed files with 103 additions and 126 deletions

View file

@ -10,6 +10,13 @@ Inductive lookup : nat -> list PTm -> PTm -> Prop :=
lookup i Γ A ->
lookup (S i) (cons B Γ) (ren_PTm shift A).
Lemma here' A Γ U : U = ren_PTm shift A -> lookup 0 (A :: Γ) U.
Proof. move => ->. apply here. Qed.
Lemma there' i Γ A B U : U = ren_PTm shift A -> lookup i Γ A ->
lookup (S i) (cons B Γ) U.
Proof. move => ->. apply there. Qed.
Derive Inversion lookup_inv with (forall i Γ A, lookup i Γ A).
Definition renaming_ok (Γ : list PTm) (Δ : list PTm) (ξ : nat -> nat) :=