Skip to content
Snippets Groups Projects
Commit b1fa82f0 authored by Ralf Jung's avatar Ralf Jung
Browse files

proofmode: show that quantifiers preserve purity

parent 997c3ed8
No related branches found
No related tags found
No related merge requests found
...@@ -31,6 +31,19 @@ Global Instance into_pure_cmra_valid `{CMRADiscrete A} (a : A) : ...@@ -31,6 +31,19 @@ Global Instance into_pure_cmra_valid `{CMRADiscrete A} (a : A) :
@IntoPure M ( a) ( a). @IntoPure M ( a) ( a).
Proof. by rewrite /IntoPure discrete_valid. Qed. Proof. by rewrite /IntoPure discrete_valid. Qed.
Global Instance into_pure_exist {X : Type} (Φ : X uPred M) φ :
( x, @IntoPure M (Φ x) (φ x)) @IntoPure M ( x, Φ x) ( x, φ x).
Proof.
rewrite /IntoPure=>Hx. apply exist_elim=>x. rewrite Hx.
apply pure_elim'=>. apply pure_intro. eauto.
Qed.
Global Instance into_pure_forall {X : Type} (Φ : X uPred M) φ :
( x, @IntoPure M (Φ x) (φ x)) @IntoPure M ( x, Φ x) ( x, φ x).
Proof.
rewrite /IntoPure=>Hx. rewrite -pure_forall_2. by setoid_rewrite Hx.
Qed.
(* FromPure *) (* FromPure *)
Global Instance from_pure_pure φ : @FromPure M φ φ. Global Instance from_pure_pure φ : @FromPure M φ φ.
Proof. done. Qed. Proof. done. Qed.
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment