packages feed

iteratee 0.8.7 → 0.8.7.1

raw patch · 3 files changed

+9/−10 lines, 3 filesdep ~test-frameworkPVP ok

version bump matches the API change (PVP)

Dependency ranges changed: test-framework

API changes (from Hackage documentation)

Files

Examples/word.hs view
@@ -12,7 +12,7 @@ import Data.Word import Data.Char import Data.ListLike as LL-import System+import System.Environment   -- | An iteratee to calculate the number of characters in a stream.@@ -44,7 +44,7 @@ -- The iteratees combined with enumPair are run in parallel. -- Any number of iteratees can be joined with multiple enumPair's. twoIter :: Monad m => I.Iteratee BC.ByteString m (Int, Int)-twoIter = numLines2 `I.enumPair` numChars+twoIter = numLines2 `I.zip` numChars  main = do   f:_ <- getArgs
iteratee.cabal view
@@ -1,5 +1,5 @@ name:          iteratee-version:       0.8.7+version:       0.8.7.1 synopsis:      Iteratee-based I/O description:   The Iteratee monad provides strict, safe, and functional I/O. In addition@@ -94,7 +94,7 @@       base                       >= 3   && < 6,       mtl                        >= 2   && < 3,       QuickCheck                 >= 2   && < 3,-      test-framework             >= 0.3 && < 0.4,+      test-framework             >= 0.3 && < 0.5,       test-framework-quickcheck2 >= 0.2 && < 0.3   else     buildable:  False
src/Data/Iteratee/Iteratee.hs view
@@ -218,12 +218,10 @@  (Monad m, NullPoint elo) =>   ((Stream eli -> Iteratee eli m a) -> Iteratee elo m (Iteratee eli m a))   -> Enumeratee elo eli m a-eneeCheckIfDone f inner = Iteratee $ \od oc -> -  let onDone x s = od (idone x s) (Chunk empty)-      onCont k Nothing  = runIter (f k) od oc-      onCont _ (Just e) = runIter (throwErr e) od oc-  in runIter inner onDone onCont-+eneeCheckIfDone f = eneeCheckIfDonePass f'+ where+  f' k Nothing  = f k+  f' k (Just e) = throwRecoverableErr e (\s -> joinIM $ enumChunk s $ eneeCheckIfDone f (liftI k))  type EnumerateeHandler eli elo m a =   (Stream eli -> Iteratee eli m a)@@ -255,6 +253,7 @@      )   -> Enumeratee elo eli m a eneeCheckIfDonePass f = eneeCheckIfDoneHandle (\k e -> f k (Just e)) f+{-# INLINE eneeCheckIfDonePass #-}  eneeCheckIfDoneIgnore   :: (Monad m, NullPoint elo)