Hoogle Search
Within LTS Haskell 24.6 (ghc-9.10.2)
Note that Stackage only displays results for the latest LTS and Nightly snapshot. Learn more.
-
A time and space-efficient implementation of vectors using packed arrays, suitable for high performance use, both in terms of large data quantities, or high speed requirements. Vectors are encoded as strict arrays, held in a ForeignPtr, and can be passed between C and Haskell with little effort. This module is intended to be imported qualified, to avoid name clashes with Prelude functions. eg.
import qualified Data.StorableVector as V
Original GHC implementation by Bryan O'Sullivan. Rewritten to use UArray by Simon Marlow. Rewritten to support slices and use ForeignPtr by David Roundy. Polished and extended by Don Stewart. Generalized to any Storable value by Spencer Janssen. Chunky lazy stream, also with chunk pattern control, mutable access in ST monad, Builder monoid by Henning Thieleman. cancelNullVector :: (Vector a, b) -> Maybe (Vector a, b)storablevector Data.StorableVector.Lazy Warning: do not use it
toLazyStorableVector :: Storable a => ChunkSize -> Builder a -> Vector astorablevector Data.StorableVector.Lazy.Builder toLazyStorableVector (ChunkSize 7) $ foldMap put ['a'..'z']
splitAtVectorPattern :: Storable a => LazySize -> Vector a -> (Vector a, Vector a)storablevector Data.StorableVector.Lazy.Pattern No documentation available.
takeVectorPattern :: Storable a => LazySize -> Vector a -> Vector astorablevector Data.StorableVector.Lazy.Pattern Preserves the chunk pattern of the lazy vector.
type
DefaultVector = Vector DefaultChunkSizestorablevector Data.StorableVector.Lazy.Typed No documentation available.
fromVectorLazy :: (Size size, Storable a) => Vector a -> Vector size astorablevector Data.StorableVector.Lazy.Typed This will maintain all laziness breaks, but if chunks are too big, they will be split.
toVectorLazy :: Vector size a -> Vector astorablevector Data.StorableVector.Lazy.Typed No documentation available.
runSTVector :: Storable e => (forall s . () => ST s (Vector s e)) -> Vector estorablevector Data.StorableVector.ST.Lazy No documentation available.
runSTVector :: Storable e => (forall s . () => ST s (Vector s e)) -> Vector estorablevector Data.StorableVector.ST.Strict No documentation available.