Module VSF := FSetFacts.Facts(VSet).Module VSP := FSetProperties.Properties(VSet).Definition match_prog (p tp: program) : Prop :=
    match_program (fun ctx f tf => transf_fundef f = OK tf) eq p tp
 /\ prog_types tp = prog_types p.

Lemma type_of_fundef_preserved: forall fd tfd, transf_fundef fd = OK tfd -> type_of_fundef tfd = type_of_fundef fd.