Fixpoint y_add1 (t: YTree): YTree :=
  match t with
  | YLeaf =>
      YLeaf
  | YNode tl v =>
      let map1 := fun u_t_pair => (tt, y_add1 (snd u_t_pair)) in
      let map2 := fun tt_u_pair => (map_tree map1 (fst tt_u_pair), tt) in
      let map3 := fun tl => map map2 tl in
      YNode (map3 tl) (v + 1)
  end.Definition ty_add1 (t: tree (unit * YTree)) :=
  map_tree (fun t => (tt, y_add1 (snd t))) t.Definition lty_add1 (t: list (tree (unit * YTree) * unit)) :=
  map (fun t => (ty_add1 (fst t), tt)) t.

(* Specifications: *)
Theorem y_add1_spec: forall t, y_add1 t = match t with | YLeaf => YLeaf | YNode tl v => YNode (lty_add1 tl) (v + 1) end.
Lemma body_Xnode_add: semax_body Vprog Gprog f_Xnode_add Xnode_add_spec.
Lemma body_Xfoo: semax_body Vprog Gprog f_Xfoo Xfoo_spec.
Lemma body_Ynode_add: semax_body Vprog Gprog f_Ynode_add Ynode_add_spec.
Lemma body_YList_add: semax_body Vprog Gprog f_YList_add YList_add_spec.
Lemma body_YTree_add: semax_body Vprog Gprog f_YTree_add YTree_add_spec.
Lemma body_main: semax_body Vprog Gprog f_main main_spec.
Lemma prog_correct: semax_prog prog Vprog Gprog.