Skip to content

Commit

Permalink
Remove unused imports.
Browse files Browse the repository at this point in the history
Due to a bug in ghc, some unused imports do not yield warnings.
This commit will remove such unused imports in preparation for
the ghc bug fix (see https://ghc.haskell.org/trac/ghc/ticket/13064).
  • Loading branch information
DavidEichmann committed Nov 8, 2018
1 parent c78be48 commit c4565cd
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions Cabal/Distribution/Compat/Prelude.hs
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,11 @@
{-# LANGUAGE FlexibleContexts #-}

#ifdef MIN_VERSION_base
#define MINVER_base_411 MIN_VERSION_base(4,11,0)
#define MINVER_base_48 MIN_VERSION_base(4,8,0)
#define MINVER_base_47 MIN_VERSION_base(4,7,0)
#else
#define MINVER_base_411 (__GLASGOW_HASKELL__ >= 804)
#define MINVER_base_48 (__GLASGOW_HASKELL__ >= 710)
#define MINVER_base_47 (__GLASGOW_HASKELL__ >= 708)
#endif
Expand Down Expand Up @@ -90,7 +92,6 @@ module Distribution.Compat.Prelude (
-- * Text.PrettyPrint
(<<>>),
) where

-- We also could hide few partial function
import Prelude as BasePrelude hiding
( IO, mapM, mapM_, sequence, null, length, foldr, any, all
Expand All @@ -117,7 +118,12 @@ import Control.DeepSeq (NFData (..))
import Data.Data (Data)
import Data.Typeable (Typeable)
import Distribution.Compat.Binary (Binary (..))
import Distribution.Compat.Semigroup (Semigroup (..), gmappend, gmempty)
#if !MINVER_base_411 && MINVER_base_48
import Distribution.Compat.Semigroup (Semigroup (..))
#endif
#if MINVER_base_48
import Distribution.Compat.Semigroup (gmappend, gmempty)
#endif
import GHC.Generics (Generic, Rep(..),
V1, U1(U1), K1(unK1), M1(unM1),
(:*:)((:*:)), (:+:)(L1,R1))
Expand Down

0 comments on commit c4565cd

Please sign in to comment.