Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Pierre-Marie Pédrot
Iris
Commits
648f146d
Commit
648f146d
authored
Sep 28, 2016
by
Robbert Krebbers
Browse files
Generic decider for emptyness of finite maps.
parent
a4383677
Changes
1
Show whitespace changes
Inline
Side-by-side
prelude/fin_maps.v
View file @
648f146d
...
...
@@ -730,6 +730,12 @@ Proof.
exists
i
,
x
.
rewrite
<-
elem_of_map_to_list
,
Hm
.
by
left
.
Qed
.
Global
Instance
map_eq_dec_empty
{
A
}
(
m
:
M
A
)
:
Decision
(
m
=
∅
)
|
20
.
Proof
.
refine
(
cast_if
(
decide
(
elements
m
=
[])))
;
[
apply
_
|
by
rewrite
<-
?map_to_list_empty'
..].
Defined
.
(** Properties of the imap function *)
Lemma
lookup_imap
{
A
B
}
(
f
:
K
→
A
→
option
B
)
m
i
:
map_imap
f
m
!!
i
=
m
!!
i
≫
=
f
i
.
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment