Definition default_val_fix_aux (y: type): (forall x, typeR x y -> reptype x) -> reptype y.Definition default_val: forall (t: type), reptype t := Fix wf_typeR reptype default_val_fix_aux.Fixpoint reptype_aux (n: nat) (t: type): Type :=
  match t with
  | Tint => val
  | Tstruct id =>
     match n with
     | O => unit
     | S n' => fold_right prod unit (map (reptype_aux n') (map snd (co_members (get_co id))))
     end
  end.Definition reptype t := reptype_aux (rank_type cenv_cs t) t.

Lemma reptype_eq: forall t: type, reptype t = match t with | Tint => val | Tstruct id => fold_right prod unit (map reptype (map snd (co_members (get_co id)))) end.