HORIZON HASKELLDocslts/ghc-9.10.xc74966e2026-09-27Search names, modules, packages, or :: a typeCtrl K

GHC 9.10.3 · lts/ghc-9.10.x · c74966e · 2026-09-27

Modulererebase-1.21.2Haskell2010

Foreign.Marshal.Array

  • 22 values
valuepeekArray :: Storable a => Int -> Ptr a -> IO [a]
#

Convert an array of given length into a Haskell list. The implementation is tail-recursive and so uses constant stack space.

valuepeekArray0 :: (Storable a, Eq a) => a -> Ptr a -> IO [a]
#

Convert an array terminated by the given end marker into a Haskell list

valuecopyArray :: Storable a => Ptr a -> Ptr a -> Int -> IO ()
#

Copy the given number of elements from the second array (source) into the first array (destination); the copied areas may not overlap

valuemoveArray :: Storable a => Ptr a -> Ptr a -> Int -> IO ()
#

Copy the given number of elements from the second array (source) into the first array (destination); the copied areas may overlap

valuenewArray :: Storable a => [a] -> IO (Ptr a)
#

Write a list of storable elements into a newly allocated, consecutive sequence of storable values (like new, but for multiple elements).

valuenewArray0 :: Storable a => a -> [a] -> IO (Ptr a)
#

Write a list of storable elements into a newly allocated, consecutive sequence of storable values, where the end is fixed by the given end marker

valuepokeArray0 :: Storable a => a -> Ptr a -> [a] -> IO ()
#

Write the list elements consecutive into memory and terminate them with the given marker element

valuewithArray :: Storable a => [a] -> (Ptr a -> IO b) -> IO b
#

Temporarily store a list of storable values in memory (like with, but for multiple elements).