Skip to content
Snippets Groups Projects
Commit 58eb623f authored by Ross Paterson's avatar Ross Paterson
Browse files

[project @ 2004-04-23 18:13:07 by ross]

Hugs: use the same version of fixIO as GHC
parent 63fecf0a
No related branches found
No related tags found
No related merge requests found
......@@ -170,6 +170,9 @@ import GHC.Show
#ifdef __HUGS__
import Hugs.IO
import Hugs.IOExts
import Hugs.IORef
import Hugs.Prelude ( throw, Exception(NonTermination) )
import System.IO.Unsafe ( unsafeInterleaveIO )
#endif
#ifdef __NHC__
......@@ -374,7 +377,7 @@ hPrint hdl = hPutStrLn hdl . show
-- ---------------------------------------------------------------------------
-- fixIO
#ifdef __GLASGOW_HASKELL__
#if defined(__GLASGOW_HASKELL__) || defined(__HUGS__)
fixIO :: (a -> IO a) -> IO a
fixIO k = do
ref <- newIORef (throw NonTermination)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment