add a simple alias to SecureMem for future refactoring

Signed-off-by: Vincent Hanquez <vincent@snarc.org>
This commit is contained in:
Vincent Hanquez 2015-04-03 07:25:22 +01:00
parent c991abda23
commit a82a544fec

View File

@ -18,6 +18,7 @@ module Crypto.Internal.Memory
, bytesAlloc
, bytesLength
, withBytes
, SecureBytes
) where
import Data.Word
@ -29,9 +30,12 @@ import Foreign.ForeignPtr
import Foreign.Storable (pokeElemOff)
import Foreign.Marshal.Alloc
import Foreign.Marshal.Utils (copyBytes)
import Data.SecureMem (SecureMem)
data Bytes = Bytes (MutableByteArray# RealWorld)
type SecureBytes = SecureMem
------------------------------------------------------------------------
newBytes :: Int -> IO Bytes
newBytes (I# sz) = IO $ \s ->