Warning police: Make some prototypes from the RTS known
authorsven.panne@aedion.de <unknown>
Fri, 11 Aug 2006 14:46:29 +0000 (14:46 +0000)
committersven.panne@aedion.de <unknown>
Fri, 11 Aug 2006 14:46:29 +0000 (14:46 +0000)
Control/Exception.hs
Debug/Trace.hs
GHC/TopHandler.lhs

index ec06bf4..38ead58 100644 (file)
@@ -518,7 +518,8 @@ uncaughtExceptionHandler = unsafePerformIO (newIORef defaultHandler)
           withCString msg $ \cmsg ->
             errorBelch cfmt cmsg
 
-foreign import ccall unsafe errorBelch :: CString -> CString -> IO ()
+foreign import ccall unsafe "RtsMessages.h errorBelch"
+   errorBelch :: CString -> CString -> IO ()
 
 setUncaughtExceptionHandler :: (Exception -> IO ()) -> IO ()
 setUncaughtExceptionHandler = writeIORef uncaughtExceptionHandler
index 4091521..accf247 100644 (file)
@@ -40,7 +40,8 @@ putTraceMsg msg = do
      withCString msg  $ \cmsg ->
       debugBelch cfmt cmsg
 
-foreign import ccall unsafe debugBelch :: CString -> CString -> IO ()
+foreign import ccall unsafe "RtsMessages.h debugBelch"
+   debugBelch :: CString -> CString -> IO ()
 #endif
 
 {-# NOINLINE trace #-}
index 686b027..3c64fc8 100644 (file)
@@ -127,12 +127,12 @@ safeExit r = unsafeCoerce# (shutdownHaskellAndExit r)
 
 -- NOTE: shutdownHaskellAndExit must be called "safe", because it *can*
 -- re-enter Haskell land through finalizers.
-foreign import ccall "shutdownHaskellAndExit" 
+foreign import ccall "Rts.h shutdownHaskellAndExit"
   shutdownHaskellAndExit :: Int -> IO ()
 
 fastExit :: Int -> IO a
 fastExit r = unsafeCoerce# (stg_exit (fromIntegral r))
 
-foreign import ccall "stg_exit" 
+foreign import ccall "Rts.h stg_exit"
   stg_exit :: CInt -> IO ()
 \end{code}