diff options
author | Jason Gross <jgross@mit.edu> | 2017-06-25 22:49:37 -0400 |
---|---|---|
committer | Jason Gross <jgross@mit.edu> | 2017-06-25 22:49:37 -0400 |
commit | c54f08a15d3dfd32f6117f067ee008039a746b0f (patch) | |
tree | 7822f95a813c46dc6dd55ea5e36a8cba57bcd5a3 /src/Util/CPSUtil.v | |
parent | 0657bd792fc299161237d5fbdb663589d93e6819 (diff) |
Prove map2_append
Diffstat (limited to 'src/Util/CPSUtil.v')
-rw-r--r-- | src/Util/CPSUtil.v | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/src/Util/CPSUtil.v b/src/Util/CPSUtil.v index adae0406b..506cda2e7 100644 --- a/src/Util/CPSUtil.v +++ b/src/Util/CPSUtil.v @@ -276,11 +276,16 @@ Module Tuple. | S n' => fun xs ys T f => map2_cps g (tl xs) (tl ys) (fun zs => f (append (g (hd xs) (hd ys)) zs)) end. - + Lemma map2_append n A B C f xs ys x y : @map2 (S n) A B C f (append x xs) (append y ys) = append (f x y) (map2 f xs ys). - Admitted. + Proof. + destruct n; try reflexivity. + cbn [append]. + rewrite map2_S'. + reflexivity. + Qed. Lemma map2_cps_correct {n A B C} g xs ys : forall {T} f, @map2_cps n A B C g xs ys T f = f (map2 g xs ys). Proof. |