[Pkg-haskell-commits] [SCM] haskell-testpack branch, master, updated. debian/1.0.2-1-4-gb0d6b36

John Goerzen jgoerzen at complete.org
Fri Apr 23 15:04:29 UTC 2010


The following commit has been merged in the master branch:
commit c11baa18742883348c1eb611139919b382965d78
Author: John Goerzen <jgoerzen at complete.org>
Date:   Fri Jan 13 22:49:53 2006 +0100

    Added a note

diff --git a/notes.txt b/notes.txt
index 7b3c675..833d6de 100644
--- a/notes.txt
+++ b/notes.txt
@@ -3,3 +3,25 @@
  dirname p  = case reverse $ dropWhile (/= '/') $ reverse p of
  [] -> "."
  p' -> p'
+
+--------------------------------------------------
+
+From: Mark Carroll <mark at ixod.org>
+Date: Sat, 15 Jan 2005 19:17:09 -0500 (EST)
+To: John Goerzen <jgoerzen at complete.org>
+Subject: Re: [Haskell-cafe] Re: Utility functions
+
+You can take the original, or this version, as being Copyright (c) 2004
+Mark Carroll under the modified BSD license. At the time of writing, it's
+the one at http://www.opensource.org/licenses/bsd-license.php
+
+splitListBy :: (a -> Bool) -> [a] -> [[a]]
+
+splitListBy isElement =
+    unfoldr splitter . (ignored :)
+    where
+    splitter [] = Nothing
+    splitter xs = Just (span isElement (tail xs))
+    ignored = error "internal failure in splitListBy"
+
+-- Mark

-- 
haskell-testpack



More information about the Pkg-haskell-commits mailing list