proposition: Lemma lower_absBody : forall E Pt A B (M: decl A E |- Pt := B) n (Menv: E |= n :!) (M'env: decl A E |= S n :!) (MLabs: isAbs (proj1_sig (lower_aux (buildT (TAbs M)) Menv))), absBody MLabs = proj1_sig (lower_aux (buildT M) M'env).
proof: Proof. intros. destruct (lower_aux (buildT M) M'env) as [P [Penv [Pterm Ptype]]]. destruct (lower_aux (buildT (TAbs M)) Menv) as [Q [Qenv [Qterm Qtype]]]. apply term_eq. rewrite absBody_env. simpl; rewrite Penv; rewrite Qenv. unfold loweredEnv, decl; simpl. replace A with (absType MLabs); simpl; trivial. rewrite (@abs_type Q MLabs A B); trivial. apply absBody_term with A. simpl; rewrite Qterm; rewrite Pterm; trivial. Qed.
imports: Coq(Compare_dec Arith Lia) CoLoR(RelExtras ListExtras LogicUtil)