induction s; intros; auto.
simpl fold'.
remember (fold' (list key) (@cons key)) as g.
rewrite <- Heqg.
rewrite <- IHs2.
f_equal. simpl.
f_equal.
apply IHs1.
Qed.

Lemma fold'_spec:  forall s (A : Type) (i : A) (f : key -> A -> A),
fold' _ f s i = List.fold_left (fun a e => f e a) (List.rev (fold' _ (@cons _) s nil)) i.