@@ -142,7 +142,7 @@ module Streamly.Internal.Data.MutArray.Type
142142 , getIndex
143143 , getIndexUnsafe
144144 , getIndices
145− , getIndicesD
145+ , getIndicesWith
146146 -- , getFromThenTo
147147 , getIndexRev
148148
@@ -1051,15 +1051,10 @@ getIndexRev i MutArray{..} = do
10511051data GetIndicesState contents start end st =
10521052 GetIndicesState contents start end st
10531053
1054−-- | Given an unfold that generates array indices, read the elements on those
1055−-- indices from the supplied MutArray. An error is thrown if an index is out of
1056−-- bounds.
1057−--
1058−-- /Pre-release/
1059−{-# INLINE getIndicesD #-}
1060−getIndicesD :: (Monad m, Unbox a) =>
1054+{-# INLINE getIndicesWith #-}
1055+getIndicesWith :: (Monad m, Unbox a) =>
10611056 (forall b. IO b -> m b) -> D.Stream m Int -> Unfold m (MutArray a) a
1062−getIndicesD liftio (D.Stream stepi sti) = Unfold step inject
1057+getIndicesWith liftio (D.Stream stepi sti) = Unfold step inject
10631058
10641059 where
10651060
@@ -1078,9 +1073,14 @@ getIndicesD liftio (D.Stream stepi sti) = Unfold step inject
10781073 D.Skip s -> return $ D.Skip (GetIndicesState contents start end s)
10791074 D.Stop -> return D.Stop
10801075
1076+-- | Given an unfold that generates array indices, read the elements on those
1077+-- indices from the supplied MutArray. An error is thrown if an index is out of
1078+-- bounds.
1079+--
1080+-- /Pre-release/
10811081{-# INLINE getIndices #-}
10821082getIndices :: (MonadIO m, Unbox a) => Stream m Int -> Unfold m (MutArray a) a
1083−getIndices = getIndicesD liftIO
1083+getIndices = getIndicesWith liftIO
10841084
10851085-------------------------------------------------------------------------------
10861086-- Subarrays