@@ -13,34 +13,9 @@
1313
1414module Streamly.Internal.Data.Fold.Combinators
1515 (
16− -- * Imports
17− -- $setup
18−
19− -- * Fold Type
20− Step (..)
21− , Fold (..)
22− , Tee (..)
23−
24− -- * Constructors
25− -- | Which constructor to use?
26− --
27− -- * @foldl*@: If the fold never terminates i.e. does not use the 'Done'
28− -- constructor otherwise use the @foldt*@ variants.
29− -- * @*M@: Use the @M@ suffix variants if any of the step, initial, or
30− -- extract function is monadic, otherwise use the pure variants.
31− --
32− , foldl'
33− , foldlM'
34− , foldl1'
35− , foldlM1'
36− , foldt'
37− , foldtM'
38− , foldr'
39− , foldrM'
40−
4116 -- * Mappers
4217 -- | Monadic functions useful with mapM/lmapM on folds or streams.
43− , tracing
18+ tracing
4419 , trace
4520
4621 -- * Folds
@@ -53,7 +28,6 @@ module Streamly.Internal.Data.Fold.Combinators
5328 , foldMapM
5429
5530 -- *** Reducers
56− , drain
5731 , drainMapM
5832 , the
5933 , length
@@ -80,13 +54,10 @@ module Streamly.Internal.Data.Fold.Combinators
8054 -- | Avoid using these folds in scalable or performance critical
8155 -- applications, they buffer all the input in GC memory which can be
8256 -- detrimental to performance if the input is large.
83− , toList
8457 , toListRev
8558 -- $toListRev
8659 , toStream
8760 , toStreamRev
88− , toStreamK
89− , toStreamKRev
9061 , topBy
9162 , top
9263 , bottomBy
@@ -106,7 +77,6 @@ module Streamly.Internal.Data.Fold.Combinators
10677
10778 -- *** Filters
10879 -- | Useful in combination with the 'scanMaybe' combinator.
109− , filtering
11080 , deleteBy
11181 , uniqBy
11282 , uniq
@@ -114,13 +84,6 @@ module Streamly.Internal.Data.Fold.Combinators
11484 , findIndices
11585 , elemIndices
11686
117− -- ** Terminating Folds
118− -- *** Empty folds
119− -- | Folds that return a result without consuming any input.
120− , fromPure
121− , fromEffect
122− , fromRefold
123−
12487 -- *** Singleton folds
12588 -- | Folds that terminate after consuming exactly one input element. All
12689 -- these can be implemented in terms of the 'maybe' fold.
@@ -150,8 +113,6 @@ module Streamly.Internal.Data.Fold.Combinators
150113
151114 -- ** Trimmers
152115 -- | Useful in combination with the 'scanMaybe' combinator.
153− , taking
154− , dropping
155116 , takingEndByM
156117 , takingEndBy
157118 , takingEndByM_
@@ -165,34 +126,14 @@ module Streamly.Internal.Data.Fold.Combinators
165126 -- , breakStream
166127
167128 -- * Building Incrementally
168− , extractM
169− , reduce
170− , close
171− , isClosed
172− , snoc
173− , snocl
174− , snocM
175− , snoclM
176−
177− , addOne
178129 , addStream
179130
180131 -- * Combinators
181132 -- ** Utilities
182133 , with
183134
184− -- ** Transforming the Monad
185− , morphInner
186− , generalizeInner
187−
188− -- ** Mapping on output
189− , rmapM
190−
191135 -- ** Mapping on Input
192136 , transform
193− , lmap
194− --, lsequence
195− , lmapM
196137
197138 -- ** Sliding Window
198139 , slide2
@@ -200,7 +141,6 @@ module Streamly.Internal.Data.Fold.Combinators
200141 -- ** Scanning Input
201142 , scan
202143 , scanMany
203− , postscan
204144 , indexed
205145
206146 -- ** Zipping Input
@@ -208,19 +148,10 @@ module Streamly.Internal.Data.Fold.Combinators
208148 , zipStream
209149
210150 -- ** Filtering Input
211− , catMaybes
212151 , mapMaybeM
213152 , mapMaybe
214− , scanMaybe
215− , filter
216− , filterM
217153 , sampleFromthen
218154
219− -- Either streams
220− , catLefts
221− , catRights
222− , catEithers
223−
224155 {-
225156 -- ** Insertion
226157 -- | Insertion adds more elements to the stream.
@@ -233,7 +164,6 @@ module Streamly.Internal.Data.Fold.Combinators
233164 -}
234165
235166 -- ** Trimming
236− , take
237167
238168 -- By elements
239169 , takeEndBy
@@ -247,18 +177,13 @@ module Streamly.Internal.Data.Fold.Combinators
247177 -}
248178
249179 -- ** Serial Append
250− , splitWith
251− , split_
252180 -- , tail
253181 -- , init
254182 , splitAt -- spanN
255183 -- , splitIn -- sessionN
256184
257185 -- ** Parallel Distribution
258− , teeWith
259186 , tee
260− , teeWithFst
261− , teeWithMin
262187 , distribute
263188 -- , distributeFst
264189 -- , distributeMin
@@ -271,10 +196,6 @@ module Streamly.Internal.Data.Fold.Combinators
271196 , unzipWithFstM
272197 , unzipWithMinM
273198
274− -- ** Parallel Alternative
275− , shortest
276− , longest
277−
278199 -- ** Partitioning
279200 , partitionByM
280201 , partitionByFstM
@@ -283,23 +204,14 @@ module Streamly.Internal.Data.Fold.Combinators
283204 , partition
284205
285206 -- ** Splitting
286− , many
287− , manyPost
288− , groupsOf
289207 , chunksBetween
290− , refoldMany
291− , refoldMany1
292208 , intersperseWithQuotes
293209
294210 -- ** Nesting
295211 , unfoldMany
296212 , concatSequence
297− , concatMap
298− , duplicate
299− , refold
300213
301214 -- * Deprecated
302− , foldr
303215 , drainBy
304216 , last
305217 , head
@@ -307,7 +219,6 @@ module Streamly.Internal.Data.Fold.Combinators
307219 , mapM
308220 , variance
309221 , stdDev
310− , serialWith
311222 )
312223where
313224
@@ -347,7 +258,6 @@ import Prelude hiding
347258 , scanl, scanl1, replicate, concatMap, mconcat, unzip
348259 , span, splitAt, break, mapM, zip, maybe)
349260import Streamly.Internal.Data.Fold.Type
350−import Streamly.Internal.Data.Fold.Tee
351261
352262#include "DocTestDataFold.hs"
353263