End IMap.
Module ZIndexed.
Definition t := Z.
Definition index (z: Z): positive :=
match z with
| Z0 => xH
| Zpos p => xO p
| Zneg p => xI p
end.

(* Specifications: *)
Lemma index_inj: forall (x y: Z), index x = index y -> x = y.
Definition eq := zeq.
Lemma index_inj: forall (x y: Z), index x = index y -> x = y.
Definition eq := zeq.