on master help sign in
update new instances in changelog
commitebf2cc87ecf81e11c65bb5f7daba4962d53c3927 authorHarendra Kumar <harendra.kumar@gmail.com> dateSun 30 Dec 2018, 23:06 (8 years ago) parentb324e13
3 files changed+10−12
Changelog.md+7−1 src/Streamly/Streams/Prelude.hs−5 src/Streamly/Streams/Serial.hs+3−6
Changelog.md+7−1
@@ -2,7 +2,8 @@
22
33### Breaking changes
44
5−* `Monad` constraint may be needed on some of the existing APIs.
5+* `Monad` constraint may be needed on some of the existing APIs (`findIndices`
6+ and `elemIndices`).
67
78### Enhancements
89
@@ -19,6 +20,11 @@
1920 * Multi-stream: `eqBy`, `cmpBy`, `mergeBy`, `mergeByM`, `mergeAsyncBy`,
2021 `mergeAsyncByM`, `isPrefixOf`, `isSubsequenceOf`, `stripPrefix`,
2122 `concatMap`, `concatMapM`, `indexed`, `indexedR`
23+* Following instances were added for `SerialT m`, `WSerialT m` and
24+ `ZipSerialM m`:
25+ * When `m` ~ `Identity`: IsList, Eq, Ord, Show, Read, IsString, NFData,
26+ NFData1, Traversable
27+ * When `m` is `Foldable`: Foldable
2228
2329## 0.5.2
2430
src/Streamly/Streams/Prelude.hs−5
@@ -75,11 +75,6 @@ toStreamS = S.fromStreamK . toStream
7575-- Conversions
7676------------------------------------------------------------------------------
7777
78−-- | Run a streaming composition, discard the results. By default it interprets
79−-- the stream as 'SerialT', to run other types of streams use the type adapting
80−-- combinators for example @run . 'asyncly'@.
81−--
82−-- @since 0.6.0
8378{-# INLINE_EARLY runStream #-}
8479runStream :: (IsStream t, Monad m) => t m a -> m ()
8580runStream m = D.runStream $ D.fromStreamK (toStream m)
src/Streamly/Streams/Serial.hs+3−6
@@ -195,6 +195,9 @@ map f = mapM (return . f)
195195
196196MONAD_APPLICATIVE_INSTANCE(SerialT,)
197197MONAD_COMMON_INSTANCES(SerialT,)
198+LIST_INSTANCES(SerialT)
199+FOLDABLE_INSTANCE(SerialT)
200+TRAVERSABLE_INSTANCE(SerialT)
198201
199202------------------------------------------------------------------------------
200203-- WSerialT
@@ -332,12 +335,6 @@ instance Monad m => Monad (WSerialT m) where
332335
333336MONAD_APPLICATIVE_INSTANCE(WSerialT,)
334337MONAD_COMMON_INSTANCES(WSerialT,)
335−
336−LIST_INSTANCES(SerialT)
337338LIST_INSTANCES(WSerialT)
338−
339−FOLDABLE_INSTANCE(SerialT)
340339FOLDABLE_INSTANCE(WSerialT)
341−
342−TRAVERSABLE_INSTANCE(SerialT)
343340TRAVERSABLE_INSTANCE(WSerialT)