Definition repinject (t: type) : reptype t -> val :=
  match t as t0 return reptype t0 -> val with
  | Tint _ _ _ => fun v => v
  | Tlong _ _ => fun v => v
  | Tfloat _ _ => fun v => v
  | Tpointer _ _ => fun v => v
  | _ => fun _ => Vundef
 end.Definition valinject (t: type) : val -> reptype t :=
  match t as t0 return val -> reptype t0 with
  | Tint _ _ _ => fun v => v
  | Tlong _ _ => fun v => v
  | Tfloat _ _ => fun v => v
  | Tpointer _ _ => fun v => v
  | t => fun _ => default_val t
 end.

(* Specifications: *)
Lemma valinject_JMeq: forall t v, type_is_by_value t = true -> JMeq (valinject t v) v.
Lemma repinject_JMeq: forall t v, type_is_by_value t = true -> JMeq (repinject t v) v.
Lemma repinject_unfold_reptype: forall t v, match t as t' return REPTYPE t' -> Prop with | Tint _ _ _ | Tfloat _ _ | Tlong _ _ | Tpointer _ _ => fun vv => repinject t v = vv | _ => fun _ => True end (unfold_reptype v).
Lemma repinject_valinject: forall t v, type_is_by_value t = true -> repinject t (valinject t v) = v.
Lemma valinject_repinject: forall t v, type_is_by_value t = true -> (valinject t (repinject t v)) = v.
Lemma repinject_default_val: forall t, repinject t (default_val t) = Vundef.
Lemma reptype_change_composite {cs_from cs_to} {CCE: change_composite_env cs_from cs_to}: forall (t: type), cs_preserve_type cs_from cs_to (coeq _ _) t = true -> @reptype cs_from t = @reptype cs_to t.
Lemma default_val_change_composite {cs_from cs_to} {CCE: change_composite_env cs_from cs_to}: forall (t: type), cs_preserve_type cs_from cs_to (coeq _ _) t = true -> JMeq (@default_val cs_from t) (@default_val cs_to t).