[project @ 2003-08-01 15:56:11 by panne]
[haskell-directory.git] / System / Environment.hs
index 0ab0214..19bccf3 100644 (file)
@@ -24,7 +24,9 @@ module System.Environment
   ) where
 
 import Prelude
-import System.IO       ( bracket )
+#ifndef __NHC__
+import Control.Exception       ( bracket )
+#endif
 
 #ifdef __GLASGOW_HASKELL__
 import Foreign
@@ -124,14 +126,15 @@ foreign import ccall unsafe "getenv"
 
 {-|
 @withArgs args act@ - while executing action @act@, have 'System.getArgs'
-return @args@.
+return @args@ (GHC only).
 -}
 withArgs xs act = do
    p <- System.Environment.getProgName
    withArgv (p:xs) act
 
 {-|
-@withProgName name act@ - while executing action @act@, have 'System.getProgName'return @name@.
+@withProgName name act@ - while executing action @act@,
+have 'System.getProgName' return @name@ (GHC only).
 -}
 withProgName nm act = do
    xs <- System.Environment.getArgs