Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
Iris
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Model registry
Operate
Terraform modules
Monitor
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Gaëtan Gilbert
Iris
Commits
c6b84830
Commit
c6b84830
authored
7 years ago
by
Robbert Krebbers
Browse files
Options
Downloads
Patches
Plain Diff
Prove stronger versions of `Persistent (P -∗ Q)` and `Plain (P -∗ Q)`.
parent
1e579d55
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
theories/bi/derived.v
+15
-19
15 additions, 19 deletions
theories/bi/derived.v
with
15 additions
and
19 deletions
theories/bi/derived.v
+
15
−
19
View file @
c6b84830
...
@@ -1757,17 +1757,6 @@ Proof.
...
@@ -1757,17 +1757,6 @@ Proof.
intros
.
by
rewrite
/
Persistent
{
2
}(
plain
P
)
-
persistently_impl_plainly
intros
.
by
rewrite
/
Persistent
{
2
}(
plain
P
)
-
persistently_impl_plainly
-
(
persistent
Q
)
(
plainly_elim_absorbingly
P
)
absorbing
.
-
(
persistent
Q
)
(
plainly_elim_absorbingly
P
)
absorbing
.
Qed
.
Qed
.
(* TODO : can we prove this lemma under positivity of the BI (or even
weaker assumptions) ? *)
Global
Instance
wand_persistent
`{
AffineBI
PROP
}
P
Q
:
Plain
P
→
Persistent
Q
→
Persistent
(
P
-∗
Q
)
.
Proof
.
intros
.
by
rewrite
/
Persistent
{
2
}(
plain
P
)
wand_impl_plainly
-
persistently_impl_plainly
-
wand_impl_plainly
-
(
persistent
Q
)
(
plainly_elim
P
)
.
Qed
.
Global
Instance
pure_wand_persistent
φ
Q
:
Persistent
Q
→
Absorbing
Q
→
Persistent
(
⌜
φ
⌝
-∗
Q
)
.
Proof
.
intros
.
rewrite
pure_wand_forall
.
apply
_
.
Qed
.
Global
Instance
sep_persistent
P
Q
:
Global
Instance
sep_persistent
P
Q
:
Persistent
P
→
Persistent
Q
→
Persistent
(
P
∗
Q
)
.
Persistent
P
→
Persistent
Q
→
Persistent
(
P
∗
Q
)
.
...
@@ -1785,6 +1774,15 @@ Global Instance from_option_persistent {A} P (Ψ : A → PROP) (mx : option A) :
...
@@ -1785,6 +1774,15 @@ Global Instance from_option_persistent {A} P (Ψ : A → PROP) (mx : option A) :
(
∀
x
,
Persistent
(
Ψ
x
))
→
Persistent
P
→
Persistent
(
from_option
Ψ
P
mx
)
.
(
∀
x
,
Persistent
(
Ψ
x
))
→
Persistent
P
→
Persistent
(
from_option
Ψ
P
mx
)
.
Proof
.
destruct
mx
;
apply
_
.
Qed
.
Proof
.
destruct
mx
;
apply
_
.
Qed
.
Global
Instance
wand_persistent
P
Q
:
Plain
P
→
Persistent
Q
→
Absorbing
Q
→
Persistent
(
P
-∗
Q
)
.
Proof
.
intros
.
rewrite
/
Persistent
{
2
}(
plain
P
)
.
trans
(
bi_persistently
(
bi_plainly
P
→
Q
))
.
-
rewrite
-
persistently_impl_plainly
-
wand_impl_affinely_plainly
-
(
persistent
Q
)
.
by
rewrite
affinely_plainly_elim
.
-
apply
persistently_mono
,
wand_intro_l
.
by
rewrite
sep_and
impl_elim_r
.
Qed
.
(* Plainness instances *)
(* Plainness instances *)
Global
Instance
pure_plain
φ
:
Plain
(
⌜
φ
⌝%
I
:
PROP
)
.
Global
Instance
pure_plain
φ
:
Plain
(
⌜
φ
⌝%
I
:
PROP
)
.
Proof
.
by
rewrite
/
Plain
plainly_pure
.
Qed
.
Proof
.
by
rewrite
/
Plain
plainly_pure
.
Qed
.
...
@@ -1815,16 +1813,14 @@ Proof.
...
@@ -1815,16 +1813,14 @@ Proof.
intros
.
by
rewrite
/
Plain
{
2
}(
plain
P
)
-
plainly_impl_plainly
-
(
plain
Q
)
intros
.
by
rewrite
/
Plain
{
2
}(
plain
P
)
-
plainly_impl_plainly
-
(
plain
Q
)
(
plainly_elim_absorbingly
P
)
absorbing
.
(
plainly_elim_absorbingly
P
)
absorbing
.
Qed
.
Qed
.
(* TODO : can we prove this lemma under positivity of the BI (or even
Global
Instance
wand_plain
P
Q
:
weaker assumptions) ? *)
Plain
P
→
Plain
Q
→
Absorbing
Q
→
Plain
(
P
-∗
Q
)
.
Global
Instance
wand_plain
`{
AffineBI
PROP
}
P
Q
:
Plain
P
→
Plain
Q
→
Plain
(
P
-∗
Q
)
.
Proof
.
Proof
.
intros
.
rewrite
/
Plain
{
2
}(
plain
P
)
wand_impl_plainly
-
plainly_impl_plainly
.
intros
.
rewrite
/
Plain
{
2
}(
plain
P
)
.
trans
(
bi_plainly
(
bi_plainly
P
→
Q
))
.
by
rewrite
-
wand_impl_plainly
-
(
plain
Q
)
(
plainly_elim
P
)
.
-
rewrite
-
plainly_impl_plainly
-
wand_impl_affinely_plainly
-
(
plain
Q
)
.
by
rewrite
affinely_plainly_elim
.
-
apply
plainly_mono
,
wand_intro_l
.
by
rewrite
sep_and
impl_elim_r
.
Qed
.
Qed
.
Global
Instance
pure_wand_plain
φ
Q
`{
!
Absorbing
Q
}
:
Plain
Q
→
Plain
(
⌜
φ
⌝
-∗
Q
)
.
Proof
.
intros
?
.
rewrite
pure_wand_forall
.
apply
_
.
Qed
.
Global
Instance
sep_plain
P
Q
:
Plain
P
→
Plain
Q
→
Plain
(
P
∗
Q
)
.
Global
Instance
sep_plain
P
Q
:
Plain
P
→
Plain
Q
→
Plain
(
P
∗
Q
)
.
Proof
.
intros
.
by
rewrite
/
Plain
-
plainly_sep_2
-!
plain
.
Qed
.
Proof
.
intros
.
by
rewrite
/
Plain
-
plainly_sep_2
-!
plain
.
Qed
.
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment