From: sewardj Date: Mon, 4 Feb 2002 13:54:53 +0000 (+0000) Subject: [project @ 2002-02-04 13:54:53 by sewardj] X-Git-Tag: Approximately_9120_patches~169 X-Git-Url: http://git.megacz.com/?a=commitdiff_plain;h=3be6a230b5b26eda562b1046357d32dcceb83158;p=ghc-hetmet.git [project @ 2002-02-04 13:54:53 by sewardj] Expand out use of modifyIORef because 4.08.2 doesn't have that. --- diff --git a/ghc/compiler/main/HscMain.lhs b/ghc/compiler/main/HscMain.lhs index 9bf5b10..60c6332 100644 --- a/ghc/compiler/main/HscMain.lhs +++ b/ghc/compiler/main/HscMain.lhs @@ -84,7 +84,7 @@ import Name ( Name, nameModule, nameOccName, getName, isGlobalName ) import NameEnv ( emptyNameEnv, mkNameEnv ) import Module ( Module ) -import IOExts ( newIORef, readIORef, writeIORef, modifyIORef, +import IOExts ( newIORef, readIORef, writeIORef, unsafePerformIO ) import Monad ( when ) @@ -351,7 +351,8 @@ hscRecomp ghci_mode dflags have_object -- ...and add the string to the headers requested via command line -- options -- - ; modifyIORef v_HCHeader (++ foreign_headers) + ; fhdrs <- readIORef v_HCHeader + ; writeIORef v_HCHeader (fhdrs ++ foreign_headers) ; imported_modules <- mapM mod_name_to_Module imported_module_names