Definition inject_memval (j:meminj) (v:memval): memval :=
     match v with
         Pointer b ofs n =>
             match j b with
                None => Undef
              | Some(b',delta) => Pointer b' (Int.add ofs (Int.repr delta)) n
             end
       | _ => v
     end.

(* Specifications: *)
Lemma inject_memval_memval_inject: forall j v v' (IM: inject_memval j v = v') (U: v' <> Undef), memval_inject j v v'.
Lemma inject_memval_memval_inject1: forall j v (H: forall b ofs n, v = Pointer b ofs n -> exists p, j b = Some p), memval_inject j v (inject_memval j v).
Lemma inject_memval_memval_inject: forall j v v' (IM: inject_memval j v = v') (U: v' <> Undef), memval_inject j v v'.
Lemma inject_memval_memval_inject1: forall j v (H: forall b ofs n, v = Pointer b ofs n -> exists p, j b = Some p), memval_inject j v (inject_memval j v).