on master help sign in
Move the zip and unzip operations in export list

Move these closer to related operations in the same class.

commitd1b678f643c996e33e6d009ca21defc29d0adb41 authorHarendra Kumar <harendra@composewell.com> dateWed 30 Mar 2022, 20:26 (5 years ago) parent7886550
1 file changed+15−12
core/src/Streamly/Internal/Data/Fold.hs+15−12
core/src/Streamly/Internal/Data/Fold.hs+15−12
@@ -130,6 +130,10 @@ module Streamly.Internal.Data.Fold
130130 , postscan
131131 , indexed
132132
133+ -- ** Zipping Input
134+ , zipWithM
135+ , zip
136+
133137 -- ** Filtering
134138 , filter
135139 , filterM
@@ -189,6 +193,14 @@ module Streamly.Internal.Data.Fold
189193 -- , distributeFst
190194 -- , distributeMin
191195
196+ -- ** Unzipping
197+ , unzip
198+ -- These two can be expressed using lmap/lmapM and unzip
199+ , unzipWith
200+ , unzipWithM
201+ , unzipWithFstM
202+ , unzipWithMinM
203+
192204 -- ** Parallel Alternative
193205 , shortest
194206 , longest
@@ -231,18 +243,6 @@ module Streamly.Internal.Data.Fold
231243 -- , classifyWithSel
232244 -- , classifyWithMin
233245
234− -- ** Unzipping
235− , unzip
236− -- These two can be expressed using lmap/lmapM and unzip
237− , unzipWith
238− , unzipWithM
239− , unzipWithFstM
240− , unzipWithMinM
241−
242− -- ** Zipping
243− , zipWithM
244− , zip
245−
246246 -- ** Splitting
247247 , many
248248 , chunksOf
@@ -1923,6 +1923,9 @@ unzip = unzipWith id
19231923-- Combining streams and folds - Zipping
19241924------------------------------------------------------------------------------
19251925
1926+-- XXX These can be implemented using the fold scan, using the stream as a
1927+-- state.
1928+--
19261929-- | Zip a stream with the input of a fold using the supplied function.
19271930--
19281931-- /Unimplemented/