From 2839722da39a0027467992b092b129dfcaec0e77 Mon Sep 17 00:00:00 2001 From: "simonpj@microsoft.com" Date: Fri, 4 Jan 2008 09:13:14 +0000 Subject: [PATCH] Remove redundant imports of GHC.Err 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 | 1 - GHC/Arr.lhs | 1 - GHC/Int.hs | 1 - GHC/List.lhs | 1 - GHC/Num.lhs | 1 - GHC/Read.lhs | 1 - GHC/Real.lhs | 1 - GHC/Word.hs | 1 - 8 files changed, 8 deletions(-) diff --git a/Data/Maybe.hs b/Data/Maybe.hs index 0e8bef5..ea16a9a 100644 --- a/Data/Maybe.hs +++ b/Data/Maybe.hs @@ -31,7 +31,6 @@ module Data.Maybe ) where #ifdef __GLASGOW_HASKELL__ -import {-# SOURCE #-} GHC.Err ( error ) import GHC.Base #endif diff --git a/GHC/Arr.lhs b/GHC/Arr.lhs index 4586fec..fe9f33d 100644 --- a/GHC/Arr.lhs +++ b/GHC/Arr.lhs @@ -17,7 +17,6 @@ -- #hide module GHC.Arr where -import {-# SOURCE #-} GHC.Err ( error ) import GHC.Enum import GHC.Num import GHC.ST diff --git a/GHC/Int.hs b/GHC/Int.hs index 3a264ef..81fb95f 100644 --- a/GHC/Int.hs +++ b/GHC/Int.hs @@ -23,7 +23,6 @@ module GHC.Int ( import Data.Bits -import {-# SOURCE #-} GHC.Err import GHC.Base import GHC.Enum import GHC.Num diff --git a/GHC/List.lhs b/GHC/List.lhs index 44aacf8..aa7dae6 100644 --- a/GHC/List.lhs +++ b/GHC/List.lhs @@ -37,7 +37,6 @@ module GHC.List ( ) where -import {-# SOURCE #-} GHC.Err ( error ) import Data.Tuple() -- Instances import Data.Maybe import GHC.Base diff --git a/GHC/Num.lhs b/GHC/Num.lhs index 67c7b18..4a74030 100644 --- a/GHC/Num.lhs +++ b/GHC/Num.lhs @@ -32,7 +32,6 @@ -- #hide module GHC.Num where -import {-# SOURCE #-} GHC.Err import GHC.Base import GHC.Enum import GHC.Show diff --git a/GHC/Read.lhs b/GHC/Read.lhs index 2610ec5..f5a6c0d 100644 --- a/GHC/Read.lhs +++ b/GHC/Read.lhs @@ -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 diff --git a/GHC/Real.lhs b/GHC/Real.lhs index 575f116..8adcea4 100644 --- a/GHC/Real.lhs +++ b/GHC/Real.lhs @@ -18,7 +18,6 @@ -- #hide module GHC.Real where -import {-# SOURCE #-} GHC.Err import GHC.Base import GHC.Num import GHC.List diff --git a/GHC/Word.hs b/GHC/Word.hs index 492e332..a2edfe8 100644 --- a/GHC/Word.hs +++ b/GHC/Word.hs @@ -26,7 +26,6 @@ module GHC.Word ( import Data.Bits -import {-# SOURCE #-} GHC.Err import GHC.Base import GHC.Enum import GHC.Num -- 1.7.10.4