[project @ 2005-03-14 15:57:57 by simonmar]
[ghc-base.git] / Foreign / ForeignPtr.hs
index a0bccf5..53275c1 100644 (file)
@@ -1,4 +1,4 @@
-{-# OPTIONS -fno-implicit-prelude #-}
+{-# OPTIONS_GHC -fno-implicit-prelude #-}
 -----------------------------------------------------------------------------
 -- |
 -- Module      :  Foreign.ForeignPtr
@@ -86,10 +86,6 @@ import GHC.ForeignPtr
 
 #if !defined(__NHC__) && !defined(__GLASGOW_HASKELL__)
 import Foreign.Marshal.Alloc   ( malloc, mallocBytes, finalizerFree )
-import Data.Typeable
-
-#include "Typeable.h"
-INSTANCE_TYPEABLE1(ForeignPtr,foreignPtrTc,"ForeignPtr")
 
 instance Eq (ForeignPtr a) where 
     p == q  =  unsafeForeignPtrToPtr p == unsafeForeignPtrToPtr q
@@ -174,7 +170,7 @@ mallocForeignPtrBytes n = do
 mallocForeignPtrArray :: Storable a => Int -> IO (ForeignPtr a)
 mallocForeignPtrArray  = doMalloc undefined
   where
-    doMalloc            :: Storable a => a -> Int -> IO (ForeignPtr a)
+    doMalloc            :: Storable b => b -> Int -> IO (ForeignPtr b)
     doMalloc dummy size  = mallocForeignPtrBytes (size * sizeOf dummy)
 
 -- | This function is similar to 'Foreign.Marshal.Array.mallocArray0',