Remove redundant imports of GHC.Err
authorsimonpj@microsoft.com <unknown>
Fri, 4 Jan 2008 09:13:14 +0000 (09:13 +0000)
committersimonpj@microsoft.com <unknown>
Fri, 4 Jan 2008 09:13:14 +0000 (09:13 +0000)
GHC.Base SOURCE-imports GHC.Err, and re-exports 'error'.  So
other modules need only import GHC.Base.

This doesn't change the fact that these other modules are all compiled
before GHC.Err, so they are all part of the module loop that starts with
GHC.Base and finishes with GHC.Err.  But it does reduce the occurrence
of those SOURCE imports.

Data/Maybe.hs
GHC/Arr.lhs
GHC/Int.hs
GHC/List.lhs
GHC/Num.lhs
GHC/Read.lhs
GHC/Real.lhs
GHC/Word.hs

index 0e8bef5..ea16a9a 100644 (file)
@@ -31,7 +31,6 @@ module Data.Maybe
    ) where
 
 #ifdef __GLASGOW_HASKELL__
-import {-# SOURCE #-} GHC.Err ( error )
 import GHC.Base
 #endif
 
index 4586fec..fe9f33d 100644 (file)
@@ -17,7 +17,6 @@
 -- #hide
 module GHC.Arr where
 
-import {-# SOURCE #-} GHC.Err ( error )
 import GHC.Enum
 import GHC.Num
 import GHC.ST
index 3a264ef..81fb95f 100644 (file)
@@ -23,7 +23,6 @@ module GHC.Int (
 
 import Data.Bits
 
-import {-# SOURCE #-} GHC.Err
 import GHC.Base
 import GHC.Enum
 import GHC.Num
index 44aacf8..aa7dae6 100644 (file)
@@ -37,7 +37,6 @@ module GHC.List (
 
  ) where
 
-import {-# SOURCE #-} GHC.Err ( error )
 import Data.Tuple()    -- Instances
 import Data.Maybe
 import GHC.Base
index 67c7b18..4a74030 100644 (file)
@@ -32,7 +32,6 @@
 -- #hide
 module GHC.Num where
 
-import {-# SOURCE #-} GHC.Err
 import GHC.Base
 import GHC.Enum
 import GHC.Show
index 2610ec5..f5a6c0d 100644 (file)
@@ -65,7 +65,6 @@ import Text.ParserCombinators.ReadPrec
 import Data.Maybe
 import Data.Either
 
-import {-# SOURCE #-} GHC.Err          ( error )
 #ifndef __HADDOCK__
 import {-# SOURCE #-} GHC.Unicode      ( isDigit )
 #endif
index 575f116..8adcea4 100644 (file)
@@ -18,7 +18,6 @@
 -- #hide
 module GHC.Real where
 
-import {-# SOURCE #-} GHC.Err
 import GHC.Base
 import GHC.Num
 import GHC.List
index 492e332..a2edfe8 100644 (file)
@@ -26,7 +26,6 @@ module GHC.Word (
 
 import Data.Bits
 
-import {-# SOURCE #-} GHC.Err
 import GHC.Base
 import GHC.Enum
 import GHC.Num