Skip to content
Snippets Groups Projects
Commit 5e7d9ca7 authored by Robbert Krebbers's avatar Robbert Krebbers
Browse files

Stronger version of `inv_open` that allows to close invariants in a different order.

parent 7143c8b7
No related branches found
No related tags found
No related merge requests found
...@@ -94,6 +94,20 @@ Proof. ...@@ -94,6 +94,20 @@ Proof.
iApply "HP'". iFrame. iApply "HP'". iFrame.
Qed. Qed.
Lemma inv_open_strong E N P :
N E
inv N P ={E,E∖↑N}=∗ P E', N E' P ={E'∖↑N,E'}=∗ True.
Proof.
iIntros (?) "Hinv".
iPoseProof (inv_open ( N) N P with "Hinv") as "H"; first done.
rewrite difference_diag_L.
iPoseProof (fupd_mask_frame_r _ _ (E N) with "H") as "H"; first set_solver.
rewrite left_id_L -union_difference_L //. iMod "H" as "[$ H]"; iModIntro.
iIntros (E' ?) "HP". iSpecialize ("H" with "HP").
iPoseProof (fupd_mask_frame_r _ _ (E' N) with "H") as "H"; first set_solver.
by rewrite left_id_L -union_difference_L.
Qed.
Lemma inv_open_timeless E N P `{!Timeless P} : Lemma inv_open_timeless E N P `{!Timeless P} :
N E inv N P ={E,E∖↑N}=∗ P (P ={E∖↑N,E}=∗ True). N E inv N P ={E,E∖↑N}=∗ P (P ={E∖↑N,E}=∗ True).
Proof. Proof.
......
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