Definition weakest_pre {CS: compspecs} (Espec: OracleKind) (Delta: tycontext) c Q: assert :=
fun rho: environ =>
ALL gx: genv, ALL Delta': tycontext,
!! (tycontext_sub Delta Delta' /\ genv_cenv gx = cenv_cs) -->
unfash (believe Espec Delta' gx Delta') -->
ALL k: cont, ALL F: assert,
unfash (!! (closed_wrt_modvars c F) && rguard Espec gx Delta' (frame_ret_assert Q F) k) -->
(* guard Espec gx Delta' (fun rho => F rho * P rho) (Kseq c :: k) *)
ALL tx : Clight.temp_env, ALL vx : env,
(!! (rho = construct_rho (filter_genv gx) vx tx)) -->
((!! guard_environ Delta' (current_function (Kseq c :: k)) rho && funassert Delta' rho) -->
(F rho -* assert_safe Espec gx vx tx (Kseq c :: k) rho)).
Opaque semax'.
Definition semax {CS: compspecs} (Espec: OracleKind) (Delta: tycontext) P c Q :=
forall n, semax' Espec Delta P c Q n.

Lemma semax_weakest_pre_aux: forall {A: Type} (P: pred nat) (Q R: A -> pred rmap),
P = fash (ALL x: A, Q x --> R x) ->
(TT |-- P <-> forall x, Q x |-- R x).