Definition semax vars (G: funspecs) (P: assert) (k: control) : Prop :=
typecheck vars k = true /\ forall n,  semax' (SemaxArg vars (fun s => P s && funassert G) k) n.
Definition semax_func (G: funspecs) (p: program) (G': funspecs) :=
match_specs p G' /\
forall n, believe_all semax' G p G' n.

Lemma semax_load: forall x y z c vars G P,
expcheck vars y = true ->
semax (vs_add x vars) G P c ->
semax vars G (fun s => ((mapsto (eval y s) z) * TT) && |> subst x z P s)
(Do x := Mem y ; c).