@@ -56,35 +56,63 @@ module Streamly.Internal.Memory.Array
5656 -- Monadic APIs
5757 -- , newArray
5858 , A.writeN -- drop new
59− , A.write -- full buffer
59+ , A.write -- full buffer
6060 -- , writeLastN -- drop old (ring buffer)
6161
6262 -- * Elimination
63− -- 'GHC.Exts.toList' from "GHC.Exts" can be used to convert an array to a
64− -- list.
6563
6664 , A.toList
6765 , toStream
6866 , toStreamRev
6967 , read
68+ -- , readChunksOf
7069
7170 -- * Random Access
7271 , length
7372 , null
73+ , last
7474 -- , (!!)
75−
7675 , readIndex
77− , last
78− {-
79− , readSlice
80− , readSliceRev
81− -}
76+ -- , readIndices
77+ -- , readRanges
78+
79+ -- , readFrom -- read from a given position to the end of file
80+ -- , readFromRev -- read from a given position to the beginning of file
81+ -- , readTo -- read from beginning up to the given position
82+ -- , readToRev -- read from end to the given position in file
83+ -- , readFromTo
84+ -- , readFromThenTo
85+
86+ -- , readChunksOfFrom
87+ -- , ...
88+
89+ -- , writeIndex
90+ -- , writeFrom -- start writing at the given position
91+ -- , writeFromRev
92+ -- , writeTo -- write from beginning up to the given position
93+ -- , writeToRev
94+ -- , writeFromTo
95+ -- , writeFromThenTo
96+ --
97+ -- , writeChunksOfFrom
98+ -- , ...
8299
83100 , writeIndex
84− {-
85− , writeSlice
86− , writeSliceRev
87− -}
101+ --, writeIndices
102+ --, writeRanges
103+
104+ -- -- * Search
105+ -- , bsearch
106+ -- , bsearchIndex
107+ -- , find
108+ -- , findIndex
109+ -- , findIndices
110+
111+ -- -- * In-pace mutation (for Mutable Array type)
112+ -- , partitionBy
113+ -- , shuffleBy
114+ -- , foldtWith
115+ -- , foldbWith
88116
89117 -- * Immutable Transformations
90118 , streamTransform
@@ -324,7 +352,7 @@ foldbWith level f = undefined
324352
325353-- | /O(1)/ Lookup the element at the given index, starting from 0.
326354--
327−-- @since 0.7.0
355+-- /Internal/
328356{-# INLINE readIndex #-}
329357readIndex :: Storable a => Array a -> Int -> Maybe a
330358readIndex arr i =