Section SemaxContext.
Hint Resolve @age_laterR : core.
(* Lemma funassert_orig_resource: forall Delta rho a a' (Hl: level a = level a') (Hr: resource_at a = resource_at a'), funassert Delta rho a -> funassert Delta rho a'. Lemma funassert_resource: forall Delta rho a a' (Hl: level a = level a') (Hr: resource_at a = resource_at a'), funassert Delta rho a -> funassert Delta rho a'.  Lemma cl_corestep_fun: forall ge m q m1 q1 m2 q2, cl_step ge q m q1 m1 -> cl_step ge q m q2 m2 -> (q1,m1)=(q2,m2).  Lemma jsafeN_local_step: forall {Espec: OracleKind} ge ora s1 m s2, cl_step  ge s1 (m_dry m) s2 (m_dry m) -> (forall m', age m m' -> jsafeN (@OK_spec Espec) ge (level m') ora s2 m') -> jsafeN (@OK_spec Espec) ge (level m) ora s1 m.  Lemma derives_skip: forall {CS: compspecs} {Espec: OracleKind} p Delta (R: ret_assert), (forall rho, p rho |-- proj_ret_assert R EK_normal None rho) -> semax Espec Delta p Clight.Sskip R.  (* Lemma jsafe_corestep_forward: forall {Espec: OracleKind} ge c m c' m' n z, jstep (cl_core_sem ge) c m c' m' -> jsafeN (@OK_spec Espec) ge (S n) z c m -> jm_bupd z (jsafeN (@OK_spec Espec) ge n z c') m'. *)

Lemma semax_unfold {CS: compspecs} {Espec: OracleKind}:
semax Espec = fun Delta P c R =>
forall (psi: Clight.genv) Delta' CS' (w: nat)
(TS: tycontext_sub Delta Delta')
(HGG: (*genv_cenv psi = cenv_cs*)cenv_sub (@cenv_cs CS) (@cenv_cs CS') /\ cenv_sub (@cenv_cs CS') (genv_cenv psi))
(Prog_OK: @believe CS' Espec Delta' psi Delta' w) (k: cont) (F: assert) f,
closed_wrt_modvars c F ->
rguard Espec psi Delta' f (frame_ret_assert R F) k w ->
guard Espec psi Delta' f (fun rho => F rho * P rho) (Kseq c k) w.