(* The derivation that is plugged in is usually canonical, i.e., [m] is zero, but we do not require this. *)
(* In the worst case, the height of the new derivation is the sum of the heights of the original derivations, due to the way the derivations are plugged in at variables. *)

Lemma inversion_JAbs:
forall E t T1 T2,
j 0 E (TAbs t) (TyArrow T1 T2) ->
exists m,
j m (insert 0 T1 E) t T2.