on master help sign in
Rename Streamly.Internal.Memory.Mutable.Array.Types
c2be163adithyaov
src/Streamly/FileSystem/FD.hs+1−1
@@ -131,7 +131,7 @@ import qualified GHC.IO.FD as FD
131import qualified GHC.IO.Device as RawIO
131import qualified GHC.IO.Device as RawIO
132
132
133import Streamly.Internal.Memory.Array.Types (Array(..), byteLength, defaultChunkSize, unsafeFreeze)
133import Streamly.Internal.Memory.Array.Types (Array(..), byteLength, defaultChunkSize, unsafeFreeze)
134−import Streamly.Internal.Memory.Mutable.Array.Types (mutableArray)
134+import Streamly.Internal.Data.Array.Storable.Foreign.Mut.Types (mutableArray)
135
135
136import Streamly.Internal.Data.Stream.Serial (SerialT)
136import Streamly.Internal.Data.Stream.Serial (SerialT)
137import Streamly.Internal.Data.Stream.StreamK.Type (IsStream, mkStream)
137import Streamly.Internal.Data.Stream.StreamK.Type (IsStream, mkStream)
src/Streamly/Internal/Data/Array/Prim/MutTypesInclude.hs+3−3
@@ -268,7 +268,7 @@ fromStreamDArraysOf n (D.Stream step state) = D.Stream step' (GroupStart state)
268 when (n <= 0) $
268 when (n <= 0) $
269 -- XXX we can pass the module string from the higher level API
269 -- XXX we can pass the module string from the higher level API
270 error $
270 error $
271− "Streamly.Internal.Memory.Mutable.Array.Types.fromStreamDArraysOf: the size of " ++
271+ "Streamly.Internal.Data.Array.Storable.Foreign.Mut.Types.fromStreamDArraysOf: the size of " ++
272 "arrays [" ++ show n ++ "] must be a natural number"
272 "arrays [" ++ show n ++ "] must be a natural number"
273 arr <- newArray n
273 arr <- newArray n
274 return $ D.Skip (GroupBuffer st arr 0)
274 return $ D.Skip (GroupBuffer st arr 0)
@@ -321,7 +321,7 @@ packArraysChunksOf n (D.Stream step state) =
321 step' gst (SpliceInitial st) = do
321 step' gst (SpliceInitial st) = do
322 when (n <= 0) $
322 when (n <= 0) $
323 -- XXX we can pass the module string from the higher level API
323 -- XXX we can pass the module string from the higher level API
324− error $ "Streamly.Internal.Memory.Mutable.Array.Types.packArraysChunksOf: the size of "
324+ error $ "Streamly.Internal.Data.Array.Storable.Foreign.Mut.Types.packArraysChunksOf: the size of "
325 ++ "arrays [" ++ show n ++ "] must be a natural number"
325 ++ "arrays [" ++ show n ++ "] must be a natural number"
326 r <- step gst st
326 r <- step gst st
327 case r of
327 case r of
@@ -365,7 +365,7 @@ lpackArraysChunksOf n (Fold step1 initial1 extract1) =
365 initial = do
365 initial = do
366 when (n <= 0) $
366 when (n <= 0) $
367 -- XXX we can pass the module string from the higher level API
367 -- XXX we can pass the module string from the higher level API
368− error $ "Streamly.Internal.Memory.Mutable.Array.Types.packArraysChunksOf: the size of "
368+ error $ "Streamly.Internal.Data.Array.Storable.Foreign.Mut.Types.packArraysChunksOf: the size of "
369 ++ "arrays [" ++ show n ++ "] must be a natural number"
369 ++ "arrays [" ++ show n ++ "] must be a natural number"
370 r1 <- initial1
370 r1 <- initial1
371 return (Tuple' Nothing r1)
371 return (Tuple' Nothing r1)
src/Streamly/Internal/Memory/Mutable/Array/Types.hs → src/Streamly/Internal/Data/Array/Storable/Foreign/Mut/Types.hsrenamed+7−7
@@ -3,7 +3,7 @@
3#include "inline.hs"
3#include "inline.hs"
4
4
5-- |
5-- |
6−-- Module : Streamly.Internal.Memory.Mutable.Array.Types
6+-- Module : Streamly.Internal.Data.Array.Storable.Foreign.Mut.Types
7-- Copyright : (c) 2020 Composewell Technologies
7-- Copyright : (c) 2020 Composewell Technologies
8--
8--
9-- License : BSD3-3-Clause
9-- License : BSD3-3-Clause
@@ -11,7 +11,7 @@
11-- Stability : experimental
11-- Stability : experimental
12-- Portability : GHC
12-- Portability : GHC
13--
13--
14−module Streamly.Internal.Memory.Mutable.Array.Types
14+module Streamly.Internal.Data.Array.Storable.Foreign.Mut.Types
15 (
15 (
16 Array (..)
16 Array (..)
17 , mutableArray
17 , mutableArray
@@ -509,7 +509,7 @@ fromStreamDArraysOf n (D.Stream step state) =
509 step' _ (GroupStart st) = do
509 step' _ (GroupStart st) = do
510 when (n <= 0) $
510 when (n <= 0) $
511 -- XXX we can pass the module string from the higher level API
511 -- XXX we can pass the module string from the higher level API
512− error $ "Streamly.Internal.Memory.Mutable.Array.Types.fromStreamDArraysOf: the size of "
512+ error $ "Streamly.Internal.Data.Array.Storable.Foreign.Mut.Types.fromStreamDArraysOf: the size of "
513 ++ "arrays [" ++ show n ++ "] must be a natural number"
513 ++ "arrays [" ++ show n ++ "] must be a natural number"
514 Array start end bound <- liftIO $ newArray n
514 Array start end bound <- liftIO $ newArray n
515 return $ D.Skip (GroupBuffer st start end bound)
515 return $ D.Skip (GroupBuffer st start end bound)
@@ -621,7 +621,7 @@ packArraysChunksOf n (D.Stream step state) =
621 step' gst (SpliceInitial st) = do
621 step' gst (SpliceInitial st) = do
622 when (n <= 0) $
622 when (n <= 0) $
623 -- XXX we can pass the module string from the higher level API
623 -- XXX we can pass the module string from the higher level API
624− error $ "Streamly.Internal.Memory.Mutable.Array.Types.packArraysChunksOf: the size of "
624+ error $ "Streamly.Internal.Data.Array.Storable.Foreign.Mut.Types.packArraysChunksOf: the size of "
625 ++ "arrays [" ++ show n ++ "] must be a natural number"
625 ++ "arrays [" ++ show n ++ "] must be a natural number"
626 r <- step gst st
626 r <- step gst st
627 case r of
627 case r of
@@ -667,7 +667,7 @@ lpackArraysChunksOf n (Fold step1 initial1 extract1) =
667 initial = do
667 initial = do
668 when (n <= 0) $
668 when (n <= 0) $
669 -- XXX we can pass the module string from the higher level API
669 -- XXX we can pass the module string from the higher level API
670− error $ "Streamly.Internal.Memory.Mutable.Array.Types.packArraysChunksOf: the size of "
670+ error $ "Streamly.Internal.Data.Array.Storable.Foreign.Mut.Types.packArraysChunksOf: the size of "
671 ++ "arrays [" ++ show n ++ "] must be a natural number"
671 ++ "arrays [" ++ show n ++ "] must be a natural number"
672 r1 <- initial1
672 r1 <- initial1
673 return (Tuple' Nothing r1)
673 return (Tuple' Nothing r1)
@@ -726,11 +726,11 @@ groupIOVecsOf n maxIOVLen (D.Stream step state) =
726 step' gst (GatherInitial st) = do
726 step' gst (GatherInitial st) = do
727 when (n <= 0) $
727 when (n <= 0) $
728 -- XXX we can pass the module string from the higher level API
728 -- XXX we can pass the module string from the higher level API
729− error $ "Streamly.Internal.Memory.Mutable.Array.Types.groupIOVecsOf: the size of "
729+ error $ "Streamly.Internal.Data.Array.Storable.Foreign.Mut.Types.groupIOVecsOf: the size of "
730 ++ "groups [" ++ show n ++ "] must be a natural number"
730 ++ "groups [" ++ show n ++ "] must be a natural number"
731 when (maxIOVLen <= 0) $
731 when (maxIOVLen <= 0) $
732 -- XXX we can pass the module string from the higher level API
732 -- XXX we can pass the module string from the higher level API
733− error $ "Streamly.Internal.Memory.Mutable.Array.Types.groupIOVecsOf: the number of "
733+ error $ "Streamly.Internal.Data.Array.Storable.Foreign.Mut.Types.groupIOVecsOf: the number of "
734 ++ "IOVec entries [" ++ show n ++ "] must be a natural number"
734 ++ "IOVec entries [" ++ show n ++ "] must be a natural number"
735 r <- step (adaptState gst) st
735 r <- step (adaptState gst) st
736 case r of
736 case r of
src/Streamly/Internal/Data/Stream/StreamD.hs+1−1
@@ -343,7 +343,7 @@ import Streamly.Internal.Data.Stream.SVar (fromConsumer, pushToFold)
343import qualified Streamly.Internal.Data.IORef.Prim as Prim
343import qualified Streamly.Internal.Data.IORef.Prim as Prim
344import qualified Streamly.Internal.Data.Pipe.Types as Pipe
344import qualified Streamly.Internal.Data.Pipe.Types as Pipe
345import qualified Streamly.Internal.Memory.Array.Types as A
345import qualified Streamly.Internal.Memory.Array.Types as A
346−import qualified Streamly.Internal.Memory.Mutable.Array.Types as MA
346+import qualified Streamly.Internal.Data.Array.Storable.Foreign.Mut.Types as MA
347import qualified Streamly.Internal.Data.Fold as FL
347import qualified Streamly.Internal.Data.Fold as FL
348import qualified Streamly.Memory.Ring as RB
348import qualified Streamly.Memory.Ring as RB
349import qualified Streamly.Internal.Data.Stream.StreamK as K
349import qualified Streamly.Internal.Data.Stream.StreamK as K
src/Streamly/Internal/FileSystem/Handle.hs+1−1
@@ -116,7 +116,7 @@ import Streamly.Internal.Data.Unfold.Types (Unfold(..))
116import Streamly.Internal.Memory.Array.Types
116import Streamly.Internal.Memory.Array.Types
117 (Array(..), writeNUnsafe, defaultChunkSize, lpackArraysChunksOf
117 (Array(..), writeNUnsafe, defaultChunkSize, lpackArraysChunksOf
118 , unsafeFreezeWithShrink)
118 , unsafeFreezeWithShrink)
119−import Streamly.Internal.Memory.Mutable.Array.Types (mutableArray)
119+import Streamly.Internal.Data.Array.Storable.Foreign.Mut.Types (mutableArray)
120import Streamly.Internal.Data.Stream.Serial (SerialT)
120import Streamly.Internal.Data.Stream.Serial (SerialT)
121import Streamly.Internal.Data.Stream.StreamK.Type (IsStream, mkStream)
121import Streamly.Internal.Data.Stream.StreamK.Type (IsStream, mkStream)
122-- import Streamly.String (encodeUtf8, decodeUtf8, foldLines)
122-- import Streamly.String (encodeUtf8, decodeUtf8, foldLines)
src/Streamly/Internal/Memory/Array/Types.hs+1−1
@@ -101,7 +101,7 @@ import Prelude hiding (length, foldr, read, unlines, splitAt)
101
101
102import qualified Streamly.Internal.Data.Stream.StreamD.Type as D
102import qualified Streamly.Internal.Data.Stream.StreamD.Type as D
103import qualified Streamly.Internal.Data.Stream.StreamK as K
103import qualified Streamly.Internal.Data.Stream.StreamK as K
104−import qualified Streamly.Internal.Memory.Mutable.Array.Types as MA
104+import qualified Streamly.Internal.Data.Array.Storable.Foreign.Mut.Types as MA
105import qualified GHC.Exts as Exts
105import qualified GHC.Exts as Exts
106
106
107#if __GLASGOW_HASKELL__ < 808
107#if __GLASGOW_HASKELL__ < 808
src/Streamly/Internal/Memory/ArrayStream.hs+1−1
@@ -47,7 +47,7 @@ import Streamly.Internal.Data.Stream.StreamK.Type (IsStream)
47
47
48import qualified Streamly.Internal.Memory.Array as A
48import qualified Streamly.Internal.Memory.Array as A
49import qualified Streamly.Internal.Memory.Array.Types as A
49import qualified Streamly.Internal.Memory.Array.Types as A
50−import qualified Streamly.Internal.Memory.Mutable.Array.Types as MA
50+import qualified Streamly.Internal.Data.Array.Storable.Foreign.Mut.Types as MA
51import qualified Streamly.Internal.Data.Stream.IsStream as S
51import qualified Streamly.Internal.Data.Stream.IsStream as S
52import qualified Streamly.Internal.Data.Stream.StreamD as D
52import qualified Streamly.Internal.Data.Stream.StreamD as D
53import qualified Streamly.Internal.Data.Stream.Prelude as P
53import qualified Streamly.Internal.Data.Stream.Prelude as P
src/Streamly/Internal/Network/Socket.hs+1−1
@@ -90,7 +90,7 @@ import qualified Network.Socket as Net
90import Streamly (MonadAsync)
90import Streamly (MonadAsync)
91import Streamly.Internal.Data.Unfold.Types (Unfold(..))
91import Streamly.Internal.Data.Unfold.Types (Unfold(..))
92import Streamly.Internal.Memory.Array.Types (Array(..), lpackArraysChunksOf)
92import Streamly.Internal.Memory.Array.Types (Array(..), lpackArraysChunksOf)
93−import Streamly.Internal.Memory.Mutable.Array.Types (mutableArray)
93+import Streamly.Internal.Data.Array.Storable.Foreign.Mut.Types (mutableArray)
94import Streamly.Internal.Data.Stream.Serial (SerialT)
94import Streamly.Internal.Data.Stream.Serial (SerialT)
95import Streamly.Internal.Data.Stream.StreamK.Type (IsStream, mkStream)
95import Streamly.Internal.Data.Stream.StreamK.Type (IsStream, mkStream)
96import Streamly.Data.Fold (Fold)
96import Streamly.Data.Fold (Fold)
streamly.cabal+1−1
@@ -429,7 +429,7 @@ library
429 , Streamly.Internal.Data.Array.Prim.Pinned.Mut.Types
429 , Streamly.Internal.Data.Array.Prim.Pinned.Mut.Types
430 , Streamly.Internal.Data.SmallArray.Types
430 , Streamly.Internal.Data.SmallArray.Types
431 , Streamly.Internal.Data.SmallArray
431 , Streamly.Internal.Data.SmallArray
432− , Streamly.Internal.Memory.Mutable.Array.Types
432+ , Streamly.Internal.Data.Array.Storable.Foreign.Mut.Types
433 , Streamly.Internal.Memory.Array.Types
433 , Streamly.Internal.Memory.Array.Types
434 , Streamly.Internal.Memory.Array
434 , Streamly.Internal.Memory.Array
435 , Streamly.Internal.Memory.ArrayStream
435 , Streamly.Internal.Memory.ArrayStream