Require Coq.Classes.EquivDec.
Require ExtLib.Data.Nat.
Set Implicit Arguments.
Set Strict Implicit.
Section type.
Variable T : Type.
Context {type_T : type T}.
Inductive list_eq : list T -> list T -> Prop :=
| nil_eq : list_eq nil nil
| cons_eq : forall x xs y ys, equal x y -> list_eq xs ys -> list_eq (x :: xs) (y :: ys).
Instance type_list : type (list T) :=
{ equal := list_eq
; proper := Forall proper
}.
Context {typeOk_T : typeOk type_T}.
Instance typeOk_list : typeOk type_list.
End type.
Section EqDec.
Variable T : Type.
Variable EqDec_T : EquivDec.EqDec _ (@eq T).
Global Instance EqDec_list : EquivDec.EqDec _ (@eq (list T)).
End EqDec.

Lemma list_rev_ind
: forall T (P : list T -> Prop),
P nil ->
(forall l ls, P ls -> P (ls ++ l :: nil)) ->
forall ls, P ls.