Commit 625d60c3 authored by Robbert Krebbers's avatar Robbert Krebbers
Browse files

Some useful BI derived lemmas.

parent ea07fcbc
...@@ -385,6 +385,9 @@ Proof. ...@@ -385,6 +385,9 @@ Proof.
apply wand_intro_l. rewrite left_absorb. auto. apply wand_intro_l. rewrite left_absorb. auto.
Qed. Qed.
Lemma wand_trans P Q R : (P - Q) (Q - R) (P - R).
Proof. apply wand_intro_l. by rewrite assoc !wand_elim_r. Qed.
Lemma wand_curry P Q R : (P - Q - R) (P Q - R). Lemma wand_curry P Q R : (P - Q - R) (P Q - R).
Proof. Proof.
apply (anti_symm _). apply (anti_symm _).
...@@ -429,6 +432,9 @@ Lemma wand_entails P Q : (P -∗ Q)%I → P ⊢ Q. ...@@ -429,6 +432,9 @@ Lemma wand_entails P Q : (P -∗ Q)%I → P ⊢ Q.
Proof. intros. rewrite -[P]emp_sep. by apply wand_elim_l'. Qed. Proof. intros. rewrite -[P]emp_sep. by apply wand_elim_l'. Qed.
Lemma entails_wand P Q : (P Q) (P - Q)%I. Lemma entails_wand P Q : (P Q) (P - Q)%I.
Proof. intros ->. apply wand_intro_r. by rewrite left_id. Qed. Proof. intros ->. apply wand_intro_r. by rewrite left_id. Qed.
(* A version that works with rewrite, in which bi_emp_valid is unfolded. *)
Lemma entails_wand' P Q : (P Q) emp (P - Q).
Proof. apply entails_wand. Qed.
Lemma equiv_wand_iff P Q : (P Q) (P - Q)%I. Lemma equiv_wand_iff P Q : (P Q) (P - Q)%I.
Proof. intros ->; apply wand_iff_refl. Qed. Proof. intros ->; apply wand_iff_refl. Qed.
......
...@@ -188,6 +188,9 @@ Proof. ...@@ -188,6 +188,9 @@ Proof.
apply plainly_mono, impl_elim with P; auto. apply plainly_mono, impl_elim with P; auto.
Qed. Qed.
Lemma plainly_emp_2 : emp @{PROP} emp.
Proof. apply plainly_emp_intro. Qed.
Lemma plainly_sep_dup P : P P P. Lemma plainly_sep_dup P : P P P.
Proof. Proof.
apply (anti_symm _). apply (anti_symm _).
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment