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
c9707f98
Commit
c9707f98
authored
7 years ago
by
Ralf Jung
Committed by
Robbert Krebbers
7 years ago
Browse files
Options
Downloads
Patches
Plain Diff
generalize savedProp to let the user control the position of the type-level later
parent
60c28208
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/base_logic/lib/saved_prop.v
+9
-8
9 additions, 8 deletions
theories/base_logic/lib/saved_prop.v
with
9 additions
and
8 deletions
theories/base_logic/lib/saved_prop.v
+
9
−
8
View file @
c9707f98
...
...
@@ -5,16 +5,17 @@ Set Default Proof Using "Type".
Import
uPred
.
Class
savedPropG
(
Σ
:
gFunctors
)
(
F
:
cFunctor
)
:=
saved_prop_inG
:>
inG
Σ
(
agreeR
(
laterC
(
F
(
iPreProp
Σ
)))
)
.
Definition
savedPropΣ
(
F
:
cFunctor
)
:
gFunctors
:=
#
[
GFunctor
(
agreeRF
(
▶
F
)
)
]
.
saved_prop_inG
:>
inG
Σ
(
agreeR
(
F
(
iPreProp
Σ
)))
.
Definition
savedPropΣ
(
F
:
cFunctor
)
`{
!
cFunctorContractive
F
}
:
gFunctors
:=
#
[
GFunctor
(
agreeRF
F
)
]
.
Instance
subG_savedPropΣ
{
Σ
F
}
:
subG
(
savedPropΣ
F
)
Σ
→
savedPropG
Σ
F
.
Instance
subG_savedPropΣ
{
Σ
F
}
`{
!
cFunctorContractive
F
}
:
subG
(
savedPropΣ
F
)
Σ
→
savedPropG
Σ
F
.
Proof
.
solve_inG
.
Qed
.
Definition
saved_prop_own
`{
savedPropG
Σ
F
}
(
γ
:
gname
)
(
x
:
F
(
iProp
Σ
))
:
iProp
Σ
:=
own
γ
(
to_agree
$
Next
(
cFunctor_map
F
(
iProp_fold
,
iProp_unfold
)
x
))
.
own
γ
(
to_agree
$
(
cFunctor_map
F
(
iProp_fold
,
iProp_unfold
)
x
))
.
Typeclasses
Opaque
saved_prop_own
.
Instance
:
Params
(
@
saved_prop_own
)
3
.
...
...
@@ -34,15 +35,15 @@ Section saved_prop.
Proof
.
by
apply
own_alloc
.
Qed
.
Lemma
saved_prop_agree
γ
x
y
:
saved_prop_own
γ
x
-∗
saved_prop_own
γ
y
-∗
▷
(
x
≡
y
)
.
saved_prop_own
γ
x
-∗
saved_prop_own
γ
y
-∗
x
≡
y
.
Proof
.
apply
wand_intro_r
.
rewrite
-
own_op
own_valid
agree_validI
agree_equivI
later_equivI
.
rewrite
-
own_op
own_valid
agree_validI
agree_equivI
.
set
(
G1
:=
cFunctor_map
F
(
iProp_fold
,
iProp_unfold
))
.
set
(
G2
:=
cFunctor_map
F
(
@
iProp_unfold
Σ
,
@
iProp_fold
Σ
))
.
assert
(
∀
z
,
G2
(
G1
z
)
≡
z
)
as
help
.
{
intros
z
.
rewrite
/
G1
/
G2
-
cFunctor_compose
-
{
2
}[
z
]
cFunctor_id
.
apply
(
ne_proper
(
cFunctor_map
F
));
split
=>?;
apply
iProp_fold_unfold
.
}
rewrite
-
{
2
}[
x
]
help
-
{
2
}[
y
]
help
.
apply
later_mono
,
f_equiv
,
_
.
rewrite
-
{
2
}[
x
]
help
-
{
2
}[
y
]
help
.
apply
f_equiv
,
_
.
Qed
.
End
saved_prop
.
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