Allow System.Posix.Internals to compile with nhc98 again.
[ghc-base.git] / GHC / IO / Device.hs
index ab91bc0..5010fef 100644 (file)
@@ -21,6 +21,7 @@ module GHC.IO.Device (
     SeekMode(..)
   ) where  
 
+#ifdef __GLASGOW_HASKELL__
 import GHC.Base
 import GHC.Word
 import GHC.Arr
@@ -32,6 +33,13 @@ import Data.Maybe
 import GHC.Num
 import GHC.IO
 import {-# SOURCE #-} GHC.IO.Exception ( unsupportedOperation )
+#endif
+#ifdef __NHC__
+import Foreign
+import Ix
+import Control.Exception.Base
+unsupportedOperation = userError "unsupported operation"
+#endif
 
 -- | A low-level I/O provider where the data is bytes in memory.
 class RawIO a where