From: panne Date: Mon, 8 May 2000 13:39:17 +0000 (+0000) Subject: [project @ 2000-05-08 13:39:17 by panne] X-Git-Tag: Approximately_9120_patches~4563 X-Git-Url: http://git.megacz.com/?a=commitdiff_plain;h=34b3142834a7d02fcc20c1423ff487059eea71f2;p=ghc-hetmet.git [project @ 2000-05-08 13:39:17 by panne] shutdownHaskellAndExit is "safe" again --- diff --git a/ghc/lib/std/System.lhs b/ghc/lib/std/System.lhs index c61cb32..7b854c3 100644 --- a/ghc/lib/std/System.lhs +++ b/ghc/lib/std/System.lhs @@ -137,10 +137,9 @@ exitWith (ExitFailure n) primExit n ioError (IOError Nothing OtherError "exitWith" "exit should not return") --- SUP: Although shutdownHaskellAndExit is declared "unsafe" below, it *can* --- re-enter Haskell land through finalizers. But this is probably not a problem, --- because it never returns. -foreign import ccall "shutdownHaskellAndExit" unsafe primExit :: Int -> IO () +-- SUP: Although shutdownHaskellAndExit must be called "safe", because it *can* +-- re-enter Haskell land through finalizers +foreign import ccall "shutdownHaskellAndExit" primExit :: Int -> IO () exitFailure :: IO a exitFailure = exitWith (ExitFailure 1)