Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
S
stdpp
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
Model registry
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
Iris
stdpp
Merge requests
!582
add some zip lemmas
Code
Review changes
Check out branch
Download
Patches
Plain diff
Merged
add some zip lemmas
kbedarka/stdpp:kimaya/add-zip-lemmas
into
master
Overview
20
Commits
3
Pipelines
14
Changes
1
All threads resolved!
Hide all comments
Merged
Kimaya Bedarkar
requested to merge
kbedarka/stdpp:kimaya/add-zip-lemmas
into
master
2 months ago
Overview
20
Commits
3
Pipelines
14
Changes
1
All threads resolved!
Hide all comments
Expand
0
0
Merge request reports
Compare
master
version 13
1549a27b
1 month ago
version 12
851230d9
1 month ago
version 11
f092fac8
1 month ago
version 10
4979bfb2
1 month ago
version 9
9ec365a1
1 month ago
version 8
52431749
1 month ago
version 7
a34ad2b1
1 month ago
version 6
cb772bab
1 month ago
version 5
25e7b53d
2 months ago
version 4
02d67bfd
2 months ago
version 3
dd74acae
2 months ago
version 2
06e33770
2 months ago
version 1
e7523111
2 months ago
master (base)
and
version 1
latest version
54d49550
3 commits,
1 month ago
version 13
1549a27b
2 commits,
1 month ago
version 12
851230d9
1 commit,
1 month ago
version 11
f092fac8
3 commits,
1 month ago
version 10
4979bfb2
2 commits,
1 month ago
version 9
9ec365a1
1 commit,
1 month ago
version 8
52431749
8 commits,
1 month ago
version 7
a34ad2b1
7 commits,
1 month ago
version 6
cb772bab
6 commits,
1 month ago
version 5
25e7b53d
5 commits,
2 months ago
version 4
02d67bfd
4 commits,
2 months ago
version 3
dd74acae
3 commits,
2 months ago
version 2
06e33770
2 commits,
2 months ago
version 1
e7523111
1 commit,
2 months ago
1 file
+
36
−
0
Inline
Compare changes
Side-by-side
Inline
Show whitespace changes
Show one file at a time
stdpp/list.v
+
36
−
0
Options
@@ -5043,6 +5043,42 @@ Section zip.
Lemma
elem_of_zip_r
x1
x2
l
k
:
(
x1
,
x2
)
∈
zip
l
k
→
x2
∈
k
.
Proof
.
intros
?
%
elem_of_zip_with
.
naive_solver
.
Qed
.
Lemma
lookup_zip
i
x1
x2
l
k
:
zip
l
k
!!
i
=
Some
(
x1
,
x2
)
→
l
!!
i
=
Some
x1
∧
k
!!
i
=
Some
x2
.
Proof
.
induction
l
as
[
|
x
xs
IH
]
in
k
,
i
|
-*
;
destruct
k
as
[
|
y
ys
];
simpl
;
[
done
.
.
|
].
destruct
i
as
[
|
i
];
simpl
;
last
by
apply
IH
.
injection
1
as
[
=
<-
]
.
naive_solver
.
Qed
.
Lemma
zip_length
l
k
:
length
(
zip
l
k
)
=
min
(
length
l
)
(
length
k
)
.
Proof
.
by
rewrite
length_zip_with
.
Qed
.
Lemma
zip_nil_implies_list_nil
l
k
:
zip
l
k
=
[]
↔
l
=
[]
∨
k
=
[]
.
Proof
.
by
induction
l
;
induction
k
;
naive_solver
.
Qed
.
Lemma
lookup_zip_split
l
k
ind
e1
e2
:
l
!!
ind
=
Some
e1
→
k
!!
ind
=
Some
e2
→
zip
l
k
!!
ind
=
Some
(
e1
,
e2
)
.
Proof
.
induction
l
as
[|
hd1
tail1
IH1
]
in
k
,
ind
|
-*
;
destruct
k
as
[
|
y
ys
];
simpl
;
[
done
.
.
|
].
intros
??
.
case
ind
as
[|
ind'
];
naive_solver
.
Qed
.
Lemma
lookup_zip_None
l
k
ind
:
length
l
=
length
k
→
zip
l
k
!!
ind
=
None
↔
l
!!
ind
=
None
∧
k
!!
ind
=
None
.
Proof
.
induction
l
as
[|
hd1
tail1
IH1
]
in
k
,
ind
|
-*
;
destruct
k
as
[
|
y
ys
];
simpl
;
[
done
.
.
|
].
case
ind
;
naive_solver
.
Qed
.
End
zip
.
Lemma
zip_diag
{
A
}
(
l
:
list
A
)
:
Loading