Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
I
iris
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
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
Tej Chajed
iris
Commits
f079e680
Commit
f079e680
authored
9 years ago
by
Robbert Krebbers
Browse files
Options
Downloads
Patches
Plain Diff
Extensionality of map on agreement.
parent
5f13409c
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
iris/agree.v
+13
-7
13 additions, 7 deletions
iris/agree.v
with
13 additions
and
7 deletions
iris/agree.v
+
13
−
7
View file @
f079e680
...
@@ -124,15 +124,21 @@ Proof.
...
@@ -124,15 +124,21 @@ Proof.
Qed
.
Qed
.
End
agree
.
End
agree
.
Program
Definition
agree_map
`{
Dist
A
,
Dist
B
}
(
f
:
A
→
B
)
(
x
:
agree
A
)
:
agree
B
:=
{|
agree_car
n
:=
f
(
x
n
);
agree_is_valid
:=
agree_is_valid
x
|}
.
Solve
Obligations
with
auto
using
agree_valid_0
,
agree_valid_S
.
Section
agree_map
.
Section
agree_map
.
Context
`{
Cofe
A
,
Cofe
B
}
(
f
:
A
→
B
)
`{
Hf
:
∀
n
,
Proper
(
dist
n
==>
dist
n
)
f
}
.
Context
`{
Cofe
A
,
Cofe
B
}
(
f
:
A
→
B
)
`{
Hf
:
∀
n
,
Proper
(
dist
n
==>
dist
n
)
f
}
.
Program
Definition
agree_map
(
x
:
agree
A
)
:
agree
B
:=
Global
Instance
agree_map_ne
n
:
Proper
(
dist
n
==>
dist
n
)
(
agree_map
f
)
.
{|
agree_car
n
:=
f
(
x
n
);
agree_is_valid
:=
agree_is_valid
x
|}
.
Solve
Obligations
with
auto
using
agree_valid_0
,
agree_valid_S
.
Global
Instance
agree_map_ne
n
:
Proper
(
dist
n
==>
dist
n
)
agree_map
.
Proof
.
by
intros
x1
x2
Hx
;
split
;
simpl
;
intros
;
[
apply
Hx
|
apply
Hf
,
Hx
]
.
Qed
.
Proof
.
by
intros
x1
x2
Hx
;
split
;
simpl
;
intros
;
[
apply
Hx
|
apply
Hf
,
Hx
]
.
Qed
.
Global
Instance
agree_map_proper
:
Proper
((
≡
)
==>
(
≡
))
agree_map
:=
ne_proper
_
.
Global
Instance
agree_map_proper
:
Global
Instance
agree_map_monotone
:
CMRAMonotone
agree_map
.
Proper
((
≡
)
==>
(
≡
))
(
agree_map
f
)
:=
ne_proper
_
.
Lemma
agree_map_ext
(
g
:
A
→
B
)
x
:
(
∀
x
,
f
x
≡
g
x
)
→
agree_map
f
x
≡
agree_map
g
x
.
Proof
.
by
intros
Hfg
;
split
;
simpl
;
intros
;
rewrite
?Hfg
.
Qed
.
Global
Instance
agree_map_monotone
:
CMRAMonotone
(
agree_map
f
)
.
Proof
.
Proof
.
split
;
[|
by
intros
n
x
[?
Hx
];
split
;
simpl
;
[|
by
intros
n'
?;
rewrite
Hx
]]
.
split
;
[|
by
intros
n
x
[?
Hx
];
split
;
simpl
;
[|
by
intros
n'
?;
rewrite
Hx
]]
.
intros
x
y
n
;
rewrite
!
agree_includedN
;
intros
Hy
;
rewrite
Hy
.
intros
x
y
n
;
rewrite
!
agree_includedN
;
intros
Hy
;
rewrite
Hy
.
...
...
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