Safe Haskell | None |
---|---|
Language | Haskell2010 |
An alternative to Storable
where the underlying byte arrays
are pinned.
- newtype Vector a = Vector {}
- newtype MVector s a = MVector {}
- callocVector :: forall a m. (PrimMonad m, Storable a) => Int -> m (MVector (PrimState m) a)
- replicate :: (PrimMonad m, Storable a) => Int -> a -> m (MVector (PrimState m) a)
- read :: (PrimMonad m, Storable a) => MVector (PrimState m) a -> Int -> m a
- write :: (PrimMonad m, Storable a) => MVector (PrimState m) a -> Int -> a -> m ()
- modify :: (PrimMonad m, Storable a) => MVector (PrimState m) a -> (a -> a) -> Int -> m ()
- unsafeRead :: (PrimMonad m, Storable a) => MVector (PrimState m) a -> Int -> m a
- unsafeWrite :: (PrimMonad m, Storable a) => MVector (PrimState m) a -> Int -> a -> m ()
- unsafeModify :: (PrimMonad m, Storable a) => MVector (PrimState m) a -> (a -> a) -> Int -> m ()
- (!) :: Storable a => Vector a -> Int -> a
- length :: Storable a => Vector a -> Int
- generate :: Storable a => Int -> (Int -> a) -> Vector a
- create :: Storable a => (forall s. ST s (MVector s a)) -> Vector a
- map :: (Storable a, Storable b) => (a -> b) -> Vector a -> Vector b
- ifilter :: Storable a => (Int -> a -> Bool) -> Vector a -> Vector a
- fromList :: Storable a => [a] -> Vector a
- getMVector :: forall a. Storable a => Handle -> MVector RealWorld a -> IO ()
Documentation
Storable a => Vector Vector a Source | |
(Eq a, Storable a) => Eq (Vector a) Source | |
(Ord a, Storable a) => Ord (Vector a) Source | |
(Read a, Storable a) => Read (Vector a) Source | |
(Show a, Storable a) => Show (Vector a) Source | |
NFData (Vector a) Source | |
Storable a => Binary (Vector a) Source | |
Newtype (RawMove a) (Vector Int) | |
type Mutable Vector = MVector Source |
Mutable interface
unsafeModify :: (PrimMonad m, Storable a) => MVector (PrimState m) a -> (a -> a) -> Int -> m () Source