Definition Iso_respects_atoms_eq   := third  respects_atoms_eq_mutual.
Definition DefEq_respects_atoms_eq := fourth respects_atoms_eq_mutual.
(* Instance Iso_atoms_eq_mor : Morphisms.Proper (eq ==> AtomSetImpl.Equal ==> eq ==> eq ==> iff) Iso.  Instance DefEq_atoms_eq_mor : Morphisms.Proper (eq ==> AtomSetImpl.Equal ==> eq ==> eq ==> eq ==> iff) DefEq.  *)
(* ----- *)
Ltac binds_cons :=
let H5 := fresh in
match goal with
[
H4 : (∃ phi : constraint, binds ?x (Co phi) ?G) → False
|- ((exists phi, binds ?x (Co phi) ([(?y, ?s)] ++ ?G)) -> False) ] =>
intro H5; destruct H5; apply H4; simpl in H5;
destruct (binds_cons_1 _ x y _ s G H5); split_hyp; subst;
try done; eauto
end.

Lemma DefEq_strengthen_available_tmvar :
forall G D g A B, DefEq G D g A B ->  forall x A', binds x (Tm A') G ->
forall D', D' [=] remove x D ->
DefEq G D' g A B.