Hoogle Search
Within LTS Haskell 24.34 (ghc-9.10.3)
Note that Stackage only displays results for the latest LTS and Nightly snapshot. Learn more.
-
vector-sized Data.Vector.Generic.Sized O(n) Apply the monadic action to all elements of a vector and ignore the results. Equivalent to flip mapM_.
force :: forall (v :: Type -> Type) a (n :: Nat) . Vector v a => Vector v n a -> Vector v n avector-sized Data.Vector.Generic.Sized O(n) Yield the argument but force it not to retain any extra memory, possibly by copying it. This is especially useful when dealing with slices. For example:
force (slice 0 2 <huge vector>)
Here, the slice retains a reference to the huge vector. Forcing it creates a copy of just the elements that belong to the slice and allows the huge vector to be garbage collected.-
vector-sized Data.Vector.Primitive.Sized O(n) Apply the monadic action to all elements of the vector, yielding a vector of results. Equvalent to flip mapM.
forM_ :: forall m a (n :: Nat) b . (Monad m, Prim a) => Vector n a -> (a -> m b) -> m ()vector-sized Data.Vector.Primitive.Sized O(n) Apply the monadic action to all elements of a vector and ignore the results. Equivalent to flip mapM_.
force :: forall a (n :: Nat) . Prim a => Vector n a -> Vector n avector-sized Data.Vector.Primitive.Sized O(n) Yield the argument but force it not to retain any extra memory, possibly by copying it. This is especially useful when dealing with slices. For example:
force (slice 0 2 <huge vector>)
Here, the slice retains a reference to the huge vector. Forcing it creates a copy of just the elements that belong to the slice and allows the huge vector to be garbage collected.forM :: forall m (n :: Nat) a b . Monad m => Vector n a -> (a -> m b) -> m (Vector n b)vector-sized Data.Vector.Sized O(n) Apply the monadic action to all elements of the vector, yielding a vector of results. Equvalent to flip mapM.
forM_ :: forall m (n :: Nat) a b . Monad m => Vector n a -> (a -> m b) -> m ()vector-sized Data.Vector.Sized O(n) Apply the monadic action to all elements of a vector and ignore the results. Equivalent to flip mapM_.
force :: forall (n :: Nat) a . Vector n a -> Vector n avector-sized Data.Vector.Sized O(n) Yield the argument but force it not to retain any extra memory, possibly by copying it. This is especially useful when dealing with slices. For example:
force (slice 0 2 <huge vector>)
Here, the slice retains a reference to the huge vector. Forcing it creates a copy of just the elements that belong to the slice and allows the huge vector to be garbage collected.-
vector-sized Data.Vector.Storable.Sized O(n) Apply the monadic action to all elements of the vector, yielding a vector of results. Equvalent to flip mapM.
forM_ :: forall m a (n :: Nat) b . (Monad m, Storable a) => Vector n a -> (a -> m b) -> m ()vector-sized Data.Vector.Storable.Sized O(n) Apply the monadic action to all elements of a vector and ignore the results. Equivalent to flip mapM_.