Section equality.
Variables A B : Type.
Variable f : A -> B.
Variables x y z : A.
End equality.
Definition eq_sind_r :
forall (A:Type) (x:A) (P:A -> SProp), P x -> forall y:A, y = x -> P y.
Register f_equal2 as core.eq.congr2.

Lemma rew_const : forall A P (x y:A) (e:x=y) (k:P),
rew [fun _ => P] e in k = k.