Skip to content

introduction of Eqdep.Eq_rect_eq.eq_rect_eq (UIP) by the usage of dependent destruction #282

@jiangsy

Description

@jiangsy

Print Assumptions rel_exp_of_typ_inversion1. (and also many other lemmas) will output

Axioms:
functional_extensionality_dep :
forall (A : Type) (B : A -> Type) (f g : forall x : A, B x), (forall x : A, f x = g x) ->
f = g
Eqdep.Eq_rect_eq.eq_rect_eq :
forall (U : Type) (p : U) (Q : U -> Type) (x : Q p) (h : p = p), x = eq_rect p Q x p h

By using the old inversion H5; subst instead of dependent destruction H5, Eqdep.Eq_rect_eq.eq_rect_eq will not be introduced. But many things need changing accordingly, so we probably don't want to fix all of them now.

Lemma rel_exp_of_typ_inversion1 : forall {Γ A A' i},
    {{ Γ ⊨ A ≈ A' : Type@i }} ->
    exists env_rel,
      {{ EF Γ ≈ Γ ∈ per_ctx_env ↘ env_rel }} /\
        forall ρ ρ' (equiv_ρ_ρ' : {{ Dom ρ ≈ ρ' ∈ env_rel }}),
          rel_exp A ρ A' ρ' (per_univ i).
Proof.
  intros * [env_relΓ].
  destruct_conjs.
  eexists;
  eexists; [eassumption |].
  intros.
  (on_all_hyp: destruct_rel_by_assumption env_relΓ). 
  destruct_by_head rel_typ.
  inversion H2; subst.
  inversion H4; subst.
  progress simp per_univ_elem in H5;
  inversion  H5; subst; 
  try rewrite <- per_univ_elem_equation_1 in *.
  handle_per_univ_elem_irrel.
  eassumption.
Qed.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions