data-ordlist 0.4.6.1 → 0.4.7.0
raw patch · 3 files changed
+20/−7 lines, 3 filesPVP ok
version bump matches the API change (PVP)
API changes (from Hackage documentation)
Files
- CHANGES.md +16/−0
- Data/List/Ordered.hs +2/−5
- data-ordlist.cabal +2/−2
CHANGES.md view
@@ -1,3 +1,19 @@+Version 0.4.7.0: (2014-11-19)++ * `foldt` tweaked to be made slightly lazier, thus also affecting+ `mergeAll`, `mergeAllBy`, `unionAll`, and `unionAllBy`. Thanks+ goes to Will Ness for providing the following example that+ previously entered into an infinite non-productive loop:++~~~+ let ps=3:minus[5,7..] (unionAll [[p*p,p*(p+2)..]|p<-ps]) in take 100 (2:ps)+~~~++ Note that the _de facto_ semantics of `foldt` has been modified+ slightly: instead of computing the sum of a list, it computes+ the sum of a list plus zero. Of course, if zero is a true+ identity of plus, then this change is of no semantic consequence.+ Version 0.4.6.1: (2014-04-19) * Added strictness annotations inside of sortOn and nubSortOn
Data/List/Ordered.hs view
@@ -470,12 +470,9 @@ -- is lazier than 'foldt''. 'foldt' is used in the implementation of -- 'mergeAll' and 'unionAll'. foldt :: (a -> a -> a) -> a -> [a] -> a-foldt plus zero xs- = case xs of- [] -> zero- (_:_) -> loop xs+foldt plus zero = loop where- loop [x] = x+ loop [] = zero loop (x:xs) = x `plus` loop (pairs xs) pairs (x:y:zs) = plus x y : pairs zs
data-ordlist.cabal view
@@ -1,5 +1,5 @@ Name: data-ordlist-Version: 0.4.6.1+Version: 0.4.7.0 Description: This module provides set and multiset operations on ordered lists. License: BSD3@@ -23,4 +23,4 @@ source-repository this type: darcs location: http://hub.darcs.net/lpsmith/data-ordlist- tag: 0.4.6.1+ tag: 0.4.7.0