-- Hoogle documentation, generated by Haddock -- See Hoogle, http://www.haskell.org/hoogle/ -- | An aligned ForeignPtr type -- -- An aligned ForeignPtr type. @package aligned-foreignptr @version 0.1 -- | A properly aligned ForeignPtr type. This can be currently achieved -- only by wasting some bytes. module Foreign.ForeignPtr.Aligned -- | The aligned ForeignPtr type data AlignedForeignPtr a -- | Should be a power of two. data Alignment -- | A "smart" constructor which checks whether the input is a power of -- two. align :: Int -> Alignment fromAlignment :: Alignment -> Int mallocAlignedForeignPtr :: Storable a => Alignment -> IO (AlignedForeignPtr a) mallocAlignedForeignPtrArray :: Storable a => Alignment -> Int -> IO (AlignedForeignPtr a) mallocAlignedForeignPtrBytes :: Alignment -> Int -> IO (AlignedForeignPtr a) withAlignedForeignPtr :: AlignedForeignPtr a -> (Ptr a -> IO b) -> IO b finalizeAlignedForeignPtr :: AlignedForeignPtr a -> IO () touchAlignedForeignPtr :: AlignedForeignPtr a -> IO () castAlignedForeignPtr :: AlignedForeignPtr a -> AlignedForeignPtr b instance Show Alignment instance Show (AlignedForeignPtr a)