Permalink
Browse files

Added and function to Generic.Data.List

  • Loading branch information...
1 parent 229ee98 commit 0d71095868ba39417f036eed603217956b368c62 @tomlokhorst committed Feb 10, 2010
Showing with 3 additions and 0 deletions.
  1. +3 −0 src/Generic/Data/List.hs
View
@@ -57,3 +57,6 @@ reverse l = rev `app` l `app` nil
where
rev = fix (\r -> lam (\xs -> lam (\a -> list a (\y ys -> r `app` ys `app` (y `cons` a)) xs)))
+and :: (BoolC j, FunC j, ListC j) => j [Bool] -> j Bool
+and = foldr (&&) true
+

0 comments on commit 0d71095

Please sign in to comment.