diff options
author | Ian Lynagh <igloo@earth.li> | 2008-03-29 18:50:43 +0000 |
---|---|---|
committer | Ian Lynagh <igloo@earth.li> | 2008-03-29 18:50:43 +0000 |
commit | 30c122df62ec75f9ed7f392f24c2925675bf1d06 (patch) | |
tree | 16d473b935d3ef5b48dbae047b9fa3093c2a3f3f /compiler | |
parent | 7c7104a51d477c18f8950112c4bc22c4800367f3 (diff) | |
download | haskell-30c122df62ec75f9ed7f392f24c2925675bf1d06.tar.gz |
Don't import FastString in HsVersions.h
Modules that need it import it themselves instead.
Diffstat (limited to 'compiler')
118 files changed, 86 insertions, 116 deletions
diff --git a/compiler/HsVersions.h b/compiler/HsVersions.h index 034a9bc07c..1ba8a01022 100644 --- a/compiler/HsVersions.h +++ b/compiler/HsVersions.h @@ -60,21 +60,12 @@ name = Util.global (value); #define WARN(e,msg) if False && (e) then pprPanic "WARN" (msg) else #endif --- This conditional lets us switch off the "import FastString" --- when compiling FastString itself, or when compiling modules that --- don't use it (and would otherwise get warnings, which we treat --- as errors). Can we do this more nicely? -#if !defined(COMPILING_FAST_STRING) && !defined(FAST_STRING_NOT_NEEDED) --- -import qualified FastString as FS -#endif - #if defined(__GLASGOW_HASKELL__) -#define SLIT(x) (FS.mkLitString# (x#)) -#define FSLIT(x) (FS.mkFastString# (x#)) +#define SLIT(x) (FastString.mkLitString# (x#)) +#define FSLIT(x) (FastString.mkFastString# (x#)) #else -#define SLIT(x) (FS.mkLitString (x)) -#define FSLIT(x) (FS.mkFastString (x)) +#define SLIT(x) (FastString.mkLitString (x)) +#define FSLIT(x) (FastString.mkFastString (x)) #endif -- Useful for declaring arguments to be strict diff --git a/compiler/basicTypes/BasicTypes.lhs b/compiler/basicTypes/BasicTypes.lhs index 7a9ff56cdf..d60321ade6 100644 --- a/compiler/basicTypes/BasicTypes.lhs +++ b/compiler/basicTypes/BasicTypes.lhs @@ -58,7 +58,7 @@ module BasicTypes( #include "HsVersions.h" -import FastString( FastString ) +import FastString import Outputable \end{code} diff --git a/compiler/basicTypes/IdInfo.lhs b/compiler/basicTypes/IdInfo.lhs index 0a54395eb8..708f4dfe58 100644 --- a/compiler/basicTypes/IdInfo.lhs +++ b/compiler/basicTypes/IdInfo.lhs @@ -92,6 +92,7 @@ import ForeignCall import NewDemand import Outputable import Module +import FastString import Data.Maybe diff --git a/compiler/basicTypes/NameEnv.lhs b/compiler/basicTypes/NameEnv.lhs index cebabdd639..0f2023b05a 100644 --- a/compiler/basicTypes/NameEnv.lhs +++ b/compiler/basicTypes/NameEnv.lhs @@ -16,8 +16,6 @@ module NameEnv ( elemNameEnv, mapNameEnv ) where --- XXX This define is a bit of a hack, and should be done more nicely -#define FAST_STRING_NOT_NEEDED 1 #include "HsVersions.h" import Name diff --git a/compiler/basicTypes/NameSet.lhs b/compiler/basicTypes/NameSet.lhs index 8776714580..e60ea23d27 100644 --- a/compiler/basicTypes/NameSet.lhs +++ b/compiler/basicTypes/NameSet.lhs @@ -22,8 +22,6 @@ module NameSet ( findUses, duDefs, duUses, allUses ) where --- XXX This define is a bit of a hack, and should be done more nicely -#define FAST_STRING_NOT_NEEDED 1 #include "HsVersions.h" import Name diff --git a/compiler/basicTypes/NewDemand.lhs b/compiler/basicTypes/NewDemand.lhs index f69d2a457b..668a35e9c2 100644 --- a/compiler/basicTypes/NewDemand.lhs +++ b/compiler/basicTypes/NewDemand.lhs @@ -23,8 +23,6 @@ module NewDemand( pprIfaceStrictSig, appIsBottom, isBottomingSig, seqStrictSig, ) where --- XXX This define is a bit of a hack, and should be done more nicely -#define FAST_STRING_NOT_NEEDED 1 #include "HsVersions.h" import StaticFlags diff --git a/compiler/basicTypes/VarEnv.lhs b/compiler/basicTypes/VarEnv.lhs index 67bc120430..bb988b2591 100644 --- a/compiler/basicTypes/VarEnv.lhs +++ b/compiler/basicTypes/VarEnv.lhs @@ -46,6 +46,7 @@ import Maybes import Outputable import FastTypes import StaticFlags +import FastString \end{code} diff --git a/compiler/basicTypes/VarSet.lhs b/compiler/basicTypes/VarSet.lhs index d4293ba459..d7e85674bf 100644 --- a/compiler/basicTypes/VarSet.lhs +++ b/compiler/basicTypes/VarSet.lhs @@ -17,8 +17,6 @@ module VarSet ( elemVarSetByKey ) where --- XXX This define is a bit of a hack, and should be done more nicely -#define FAST_STRING_NOT_NEEDED 1 #include "HsVersions.h" import Var diff --git a/compiler/cmm/CmmCPSGen.hs b/compiler/cmm/CmmCPSGen.hs index 55a7397a68..0d409aba70 100644 --- a/compiler/cmm/CmmCPSGen.hs +++ b/compiler/cmm/CmmCPSGen.hs @@ -33,6 +33,7 @@ import StaticFlags import Unique import Maybe import List +import FastString import Panic diff --git a/compiler/cmm/CmmInfo.hs b/compiler/cmm/CmmInfo.hs index 49a77e29fd..c0e217c1cc 100644 --- a/compiler/cmm/CmmInfo.hs +++ b/compiler/cmm/CmmInfo.hs @@ -276,6 +276,3 @@ mkStdInfoTable type_descr closure_descr cl_type srt_len layout_lit type_lit = packHalfWordsCLit cl_type srt_len - -_unused :: FS.FastString -- stops a warning -_unused = undefined diff --git a/compiler/cmm/CmmLint.hs b/compiler/cmm/CmmLint.hs index e376e56d47..c4aee8adb6 100644 --- a/compiler/cmm/CmmLint.hs +++ b/compiler/cmm/CmmLint.hs @@ -27,6 +27,7 @@ import Outputable import PprCmm import Unique import Constants +import FastString import Control.Monad diff --git a/compiler/cmm/CmmOpt.hs b/compiler/cmm/CmmOpt.hs index 4d0390d817..6adafb5feb 100644 --- a/compiler/cmm/CmmOpt.hs +++ b/compiler/cmm/CmmOpt.hs @@ -574,5 +574,3 @@ isComparisonExpr _other = False isPicReg (CmmReg (CmmGlobal PicBaseReg)) = True isPicReg _ = False -_unused :: FS.FastString -- stops a warning -_unused = undefined diff --git a/compiler/cmm/MachOp.hs b/compiler/cmm/MachOp.hs index 10cc0cd04b..8f55000972 100644 --- a/compiler/cmm/MachOp.hs +++ b/compiler/cmm/MachOp.hs @@ -90,6 +90,7 @@ module MachOp ( import Constants import Outputable +import FastString -- ----------------------------------------------------------------------------- -- MachRep diff --git a/compiler/cmm/MkZipCfg.hs b/compiler/cmm/MkZipCfg.hs index 484068ab73..067e74956c 100644 --- a/compiler/cmm/MkZipCfg.hs +++ b/compiler/cmm/MkZipCfg.hs @@ -360,5 +360,3 @@ Emitting a Branch at this point is fine: freshBlockId :: String -> UniqSM BlockId freshBlockId _ = do { u <- getUniqueUs; return $ BlockId u } -_unused :: FS.FastString -_unused = undefined diff --git a/compiler/cmm/OptimizationFuel.hs b/compiler/cmm/OptimizationFuel.hs index 6e05cdc68b..bc32626c98 100644 --- a/compiler/cmm/OptimizationFuel.hs +++ b/compiler/cmm/OptimizationFuel.hs @@ -48,11 +48,6 @@ oneLessFuel f = f diffFuel _ _ = 0 #endif --- stop warnings about things that aren't used -_unused :: {-State#-} () -> FS.FastString -_unused = undefined panic - - data FuelState = FuelState { fs_fuellimit :: OptimizationFuel, fs_lastpass :: String } newtype FuelMonad a = FuelMonad (FuelState -> (a, FuelState)) diff --git a/compiler/cmm/ZipCfg.hs b/compiler/cmm/ZipCfg.hs index 1b9b5c309d..f07d2fa56e 100644 --- a/compiler/cmm/ZipCfg.hs +++ b/compiler/cmm/ZipCfg.hs @@ -707,5 +707,3 @@ pprGraph (Graph tail blockenv) = where pprBlock (Block id tail) = ppr id <> colon $$ ppr tail blocks = postorder_dfs_from blockenv tail -_unused :: FS.FastString -_unused = undefined diff --git a/compiler/cmm/ZipDataflow0.hs b/compiler/cmm/ZipDataflow0.hs index 7503d45104..00f15dbe35 100644 --- a/compiler/cmm/ZipDataflow0.hs +++ b/compiler/cmm/ZipDataflow0.hs @@ -1088,10 +1088,6 @@ subAnalysis' m = where pprFacts env = nest 2 $ vcat $ map pprFact $ ufmToList env pprFact (id, a) = hang (ppr id <> colon) 4 (ppr a) - -_unused :: FS.FastString -_unused = undefined - null_b_ft = BComp "do nothing" Nothing no2 no2 no2 where no2 _ _ = Nothing diff --git a/compiler/codeGen/CgBindery.lhs b/compiler/codeGen/CgBindery.lhs index d9ddddb8bd..2ea13f6ad8 100644 --- a/compiler/codeGen/CgBindery.lhs +++ b/compiler/codeGen/CgBindery.lhs @@ -62,6 +62,7 @@ import StgSyn import Unique import UniqSet import Outputable +import FastString \end{code} diff --git a/compiler/codeGen/CgCon.lhs b/compiler/codeGen/CgCon.lhs index 711c633fd8..b7dde73a97 100644 --- a/compiler/codeGen/CgCon.lhs +++ b/compiler/codeGen/CgCon.lhs @@ -52,6 +52,7 @@ import PrelInfo import Outputable import ListSetOps import Util +import FastString \end{code} diff --git a/compiler/codeGen/CgForeignCall.hs b/compiler/codeGen/CgForeignCall.hs index 8e1be19beb..e9a542e5d1 100644 --- a/compiler/codeGen/CgForeignCall.hs +++ b/compiler/codeGen/CgForeignCall.hs @@ -43,6 +43,7 @@ import ClosureInfo import Constants import StaticFlags import Outputable +import FastString import Control.Monad diff --git a/compiler/codeGen/CgHeapery.lhs b/compiler/codeGen/CgHeapery.lhs index 9cb1bb4370..4592e1964e 100644 --- a/compiler/codeGen/CgHeapery.lhs +++ b/compiler/codeGen/CgHeapery.lhs @@ -52,6 +52,7 @@ import Util import Constants import PackageConfig import Outputable +import FastString import Data.List \end{code} diff --git a/compiler/codeGen/CgPrimOp.hs b/compiler/codeGen/CgPrimOp.hs index c77e8e5968..207ffe27d7 100644 --- a/compiler/codeGen/CgPrimOp.hs +++ b/compiler/codeGen/CgPrimOp.hs @@ -35,6 +35,7 @@ import PrimOp import SMRep import Constants import Outputable +import FastString -- --------------------------------------------------------------------------- -- Code generation for PrimOps diff --git a/compiler/codeGen/CgTailCall.lhs b/compiler/codeGen/CgTailCall.lhs index cd100e8f21..475196abba 100644 --- a/compiler/codeGen/CgTailCall.lhs +++ b/compiler/codeGen/CgTailCall.lhs @@ -474,8 +474,3 @@ adjustSpAndHp newRealSp } \end{code} -Some things are unused. -\begin{code} -_unused :: FS.FastString -_unused = undefined -\end{code} diff --git a/compiler/codeGen/SMRep.lhs b/compiler/codeGen/SMRep.lhs index 4bc122222e..1845c449d4 100644 --- a/compiler/codeGen/SMRep.lhs +++ b/compiler/codeGen/SMRep.lhs @@ -53,6 +53,7 @@ import MachOp import StaticFlags import Constants import Outputable +import FastString import Data.Word \end{code} diff --git a/compiler/coreSyn/CoreFVs.lhs b/compiler/coreSyn/CoreFVs.lhs index 57316c7211..7b0f027f09 100644 --- a/compiler/coreSyn/CoreFVs.lhs +++ b/compiler/coreSyn/CoreFVs.lhs @@ -30,8 +30,6 @@ module CoreFVs ( freeVarsOf -- CoreExprWithFVs -> IdSet ) where --- XXX This define is a bit of a hack, and should be done more nicely -#define FAST_STRING_NOT_NEEDED 1 #include "HsVersions.h" import CoreSyn diff --git a/compiler/coreSyn/CoreLint.lhs b/compiler/coreSyn/CoreLint.lhs index e903c6a39c..345fb733c7 100644 --- a/compiler/coreSyn/CoreLint.lhs +++ b/compiler/coreSyn/CoreLint.lhs @@ -39,6 +39,7 @@ import StaticFlags import ListSetOps import DynFlags import Outputable +import FastString import Util import Data.Maybe \end{code} diff --git a/compiler/coreSyn/CorePrep.lhs b/compiler/coreSyn/CorePrep.lhs index 4d942611e3..f0c2d9fc53 100644 --- a/compiler/coreSyn/CorePrep.lhs +++ b/compiler/coreSyn/CorePrep.lhs @@ -35,6 +35,7 @@ import DynFlags import Util import Outputable import MonadUtils +import FastString \end{code} -- --------------------------------------------------------------------------- diff --git a/compiler/coreSyn/CoreSubst.lhs b/compiler/coreSyn/CoreSubst.lhs index 503432da51..adeeaddfb2 100644 --- a/compiler/coreSyn/CoreSubst.lhs +++ b/compiler/coreSyn/CoreSubst.lhs @@ -43,6 +43,7 @@ import UniqSupply import Maybes import Outputable import PprCore () -- Instances +import FastString import Data.List \end{code} diff --git a/compiler/coreSyn/CoreTidy.lhs b/compiler/coreSyn/CoreTidy.lhs index 5acee51f42..3f8402131a 100644 --- a/compiler/coreSyn/CoreTidy.lhs +++ b/compiler/coreSyn/CoreTidy.lhs @@ -11,8 +11,6 @@ module CoreTidy ( tidyExpr, tidyVarOcc, tidyRule, tidyRules ) where --- XXX This define is a bit of a hack, and should be done more nicely -#define FAST_STRING_NOT_NEEDED 1 #include "HsVersions.h" import CoreSyn diff --git a/compiler/coreSyn/CoreUnfold.lhs b/compiler/coreSyn/CoreUnfold.lhs index 767006076d..8da91ed924 100644 --- a/compiler/coreSyn/CoreUnfold.lhs +++ b/compiler/coreSyn/CoreUnfold.lhs @@ -48,6 +48,7 @@ import Type import PrelNames import Bag import FastTypes +import FastString import Outputable \end{code} diff --git a/compiler/deSugar/DsGRHSs.lhs b/compiler/deSugar/DsGRHSs.lhs index 683dd2197e..83ceeca17b 100644 --- a/compiler/deSugar/DsGRHSs.lhs +++ b/compiler/deSugar/DsGRHSs.lhs @@ -15,8 +15,6 @@ Matching guarded right-hand-sides (GRHSs) module DsGRHSs ( dsGuarded, dsGRHSs ) where --- XXX This define is a bit of a hack, and should be done more nicely -#define FAST_STRING_NOT_NEEDED 1 #include "HsVersions.h" import {-# SOURCE #-} DsExpr ( dsLExpr, dsLocalBinds ) diff --git a/compiler/deSugar/DsListComp.lhs b/compiler/deSugar/DsListComp.lhs index e5e1fd9472..03da525549 100644 --- a/compiler/deSugar/DsListComp.lhs +++ b/compiler/deSugar/DsListComp.lhs @@ -15,8 +15,6 @@ Desugaring list comprehensions and array comprehensions module DsListComp ( dsListComp, dsPArrComp ) where --- XXX This define is a bit of a hack, and should be done more nicely -#define FAST_STRING_NOT_NEEDED 1 #include "HsVersions.h" import {-# SOURCE #-} DsExpr ( dsLExpr, dsLocalBinds ) diff --git a/compiler/deSugar/DsMonad.lhs b/compiler/deSugar/DsMonad.lhs index 52b7705660..10cd28ac18 100644 --- a/compiler/deSugar/DsMonad.lhs +++ b/compiler/deSugar/DsMonad.lhs @@ -59,6 +59,7 @@ import OccName import DynFlags import ErrUtils import MonadUtils +import FastString import Data.IORef \end{code} diff --git a/compiler/deSugar/Match.lhs b/compiler/deSugar/Match.lhs index 793cc56391..a7e9bce188 100644 --- a/compiler/deSugar/Match.lhs +++ b/compiler/deSugar/Match.lhs @@ -43,6 +43,7 @@ import Maybes import Util import Name import Outputable +import FastString \end{code} This function is a wrapper of @match@, it must be called from all the parts where diff --git a/compiler/deSugar/MatchCon.lhs b/compiler/deSugar/MatchCon.lhs index 3baa9666e9..4e9ee8e3f7 100644 --- a/compiler/deSugar/MatchCon.lhs +++ b/compiler/deSugar/MatchCon.lhs @@ -15,8 +15,6 @@ Pattern-matching constructors module MatchCon ( matchConFamily ) where --- XXX This define is a bit of a hack, and should be done more nicely -#define FAST_STRING_NOT_NEEDED 1 #include "HsVersions.h" import {-# SOURCE #-} Match ( match ) diff --git a/compiler/ghci/RtClosureInspect.hs b/compiler/ghci/RtClosureInspect.hs index 269a7bb1d2..8941638663 100644 --- a/compiler/ghci/RtClosureInspect.hs +++ b/compiler/ghci/RtClosureInspect.hs @@ -68,6 +68,7 @@ import PrelNames import TysWiredIn import Outputable +import FastString import Panic #ifndef GHCI_TABLES_NEXT_TO_CODE diff --git a/compiler/hsSyn/HsBinds.lhs b/compiler/hsSyn/HsBinds.lhs index 07c631a62c..d1c2234cc0 100644 --- a/compiler/hsSyn/HsBinds.lhs +++ b/compiler/hsSyn/HsBinds.lhs @@ -35,6 +35,7 @@ import SrcLoc import Util import Var import Bag +import FastString \end{code} %************************************************************************ diff --git a/compiler/hsSyn/HsDoc.hs b/compiler/hsSyn/HsDoc.hs index dc7245d4d3..fd721c00c0 100644 --- a/compiler/hsSyn/HsDoc.hs +++ b/compiler/hsSyn/HsDoc.hs @@ -6,8 +6,6 @@ module HsDoc ( ppr_mbDoc ) where --- XXX This define is a bit of a hack, and should be done more nicely -#define FAST_STRING_NOT_NEEDED 1 #include "HsVersions.h" import Outputable diff --git a/compiler/hsSyn/HsSyn.lhs b/compiler/hsSyn/HsSyn.lhs index 66f663328a..20e339f1f5 100644 --- a/compiler/hsSyn/HsSyn.lhs +++ b/compiler/hsSyn/HsSyn.lhs @@ -46,6 +46,7 @@ import IfaceSyn ( IfaceBinding ) import Outputable import SrcLoc ( Located(..) ) import Module ( Module, ModuleName ) +import FastString \end{code} All we actually declare here is the top-level structure for a module. diff --git a/compiler/hsSyn/HsTypes.lhs b/compiler/hsSyn/HsTypes.lhs index 2b3fc09b14..25d6566f16 100644 --- a/compiler/hsSyn/HsTypes.lhs +++ b/compiler/hsSyn/HsTypes.lhs @@ -38,6 +38,7 @@ import BasicTypes import SrcLoc import StaticFlags import Outputable +import FastString \end{code} diff --git a/compiler/iface/LoadIface.lhs b/compiler/iface/LoadIface.lhs index 6211176f87..feb51d1b73 100644 --- a/compiler/iface/LoadIface.lhs +++ b/compiler/iface/LoadIface.lhs @@ -58,6 +58,7 @@ import Outputable import BinIface import Panic import Util +import FastString import Control.Monad import Data.List diff --git a/compiler/iface/TcIface.lhs b/compiler/iface/TcIface.lhs index b50ff7fb66..e1a6d2bd40 100644 --- a/compiler/iface/TcIface.lhs +++ b/compiler/iface/TcIface.lhs @@ -58,8 +58,9 @@ import Maybes import SrcLoc import DynFlags import Util -import Control.Monad +import FastString +import Control.Monad import Data.List import Data.Maybe \end{code} diff --git a/compiler/main/CmdLineParser.hs b/compiler/main/CmdLineParser.hs index c7ad66e922..8ec2f6a3ef 100644 --- a/compiler/main/CmdLineParser.hs +++ b/compiler/main/CmdLineParser.hs @@ -14,8 +14,6 @@ module CmdLineParser ( CmdLineP(..), getCmdLineState, putCmdLineState ) where --- XXX This define is a bit of a hack, and should be done more nicely -#define FAST_STRING_NOT_NEEDED 1 #include "HsVersions.h" import Util diff --git a/compiler/main/Constants.lhs b/compiler/main/Constants.lhs index d26db11b9e..51971728a0 100644 --- a/compiler/main/Constants.lhs +++ b/compiler/main/Constants.lhs @@ -13,8 +13,6 @@ import Data.Bits (shiftL) -- we want; if we just hope a -I... will get the right one, we could -- be in trouble. --- XXX This define is a bit of a hack, and should be done more nicely -#define FAST_STRING_NOT_NEEDED 1 #include "HsVersions.h" #include "../includes/MachRegs.h" #include "../includes/Constants.h" diff --git a/compiler/main/DriverMkDepend.hs b/compiler/main/DriverMkDepend.hs index 901b3bb7ce..4155274e31 100644 --- a/compiler/main/DriverMkDepend.hs +++ b/compiler/main/DriverMkDepend.hs @@ -35,6 +35,7 @@ import Panic import SrcLoc import Data.List import CmdLineParser +import FastString import ErrUtils ( debugTraceMsg, putMsg ) diff --git a/compiler/main/DriverPipeline.hs b/compiler/main/DriverPipeline.hs index 50b45017c4..59535f040c 100644 --- a/compiler/main/DriverPipeline.hs +++ b/compiler/main/DriverPipeline.hs @@ -45,6 +45,7 @@ import Maybes ( expectJust ) import ParserCoreUtils ( getCoreModuleName ) import SrcLoc ( unLoc ) import SrcLoc ( Located(..) ) +import FastString import Control.Exception as Exception import Data.IORef ( readIORef, writeIORef, IORef ) diff --git a/compiler/main/DynFlags.hs b/compiler/main/DynFlags.hs index 3645e080cf..7fc2c9a01c 100644 --- a/compiler/main/DynFlags.hs +++ b/compiler/main/DynFlags.hs @@ -60,8 +60,6 @@ module DynFlags ( compilerInfo, ) where --- XXX This define is a bit of a hack, and should be done more nicely -#define FAST_STRING_NOT_NEEDED 1 #include "HsVersions.h" import Module diff --git a/compiler/main/ErrUtils.lhs b/compiler/main/ErrUtils.lhs index 455b3bfe37..9ce02a3d2c 100644 --- a/compiler/main/ErrUtils.lhs +++ b/compiler/main/ErrUtils.lhs @@ -28,8 +28,6 @@ module ErrUtils ( debugTraceMsg, ) where --- XXX This define is a bit of a hack, and should be done more nicely -#define FAST_STRING_NOT_NEEDED 1 #include "HsVersions.h" import Bag ( Bag, bagToList, isEmptyBag, emptyBag ) diff --git a/compiler/main/GHC.hs b/compiler/main/GHC.hs index 0caa1cbbf7..bd6eee6a1b 100644 --- a/compiler/main/GHC.hs +++ b/compiler/main/GHC.hs @@ -266,6 +266,7 @@ import BasicTypes import Maybes ( expectJust, mapCatMaybes ) import HaddockParse import HaddockLex ( tokenise ) +import FastString import Control.Concurrent import System.Directory ( getModificationTime, doesFileExist, diff --git a/compiler/main/HscStats.lhs b/compiler/main/HscStats.lhs index 52e396dcde..e717bfec64 100644 --- a/compiler/main/HscStats.lhs +++ b/compiler/main/HscStats.lhs @@ -6,8 +6,6 @@ \begin{code} module HscStats ( ppSourceStats ) where --- XXX This define is a bit of a hack, and should be done more nicely -#define FAST_STRING_NOT_NEEDED 1 #include "HsVersions.h" import HsSyn diff --git a/compiler/main/HscTypes.lhs b/compiler/main/HscTypes.lhs index 07c7568497..ec872626d0 100644 --- a/compiler/main/HscTypes.lhs +++ b/compiler/main/HscTypes.lhs @@ -112,7 +112,7 @@ import BreakArray import SrcLoc ( SrcSpan, Located ) import LazyUniqFM ( lookupUFM, eltsUFM, emptyUFM ) import UniqSupply ( UniqSupply ) -import FastString ( FastString ) +import FastString import StringBuffer ( StringBuffer ) import System.FilePath diff --git a/compiler/main/PackageConfig.hs b/compiler/main/PackageConfig.hs index c070ca2efb..80488ec05f 100644 --- a/compiler/main/PackageConfig.hs +++ b/compiler/main/PackageConfig.hs @@ -22,10 +22,6 @@ import Distribution.Package import Distribution.Version import Distribution.Compat.ReadP ( readP_to_S ) --- warning suppression -_unused :: FS.FastString -_unused = FSLIT("") - -- ----------------------------------------------------------------------------- -- Our PackageConfig type is just InstalledPackageInfo from Cabal. Later we -- might need to extend it with some GHC-specific stuff, but for now it's fine. diff --git a/compiler/main/PprTyThing.hs b/compiler/main/PprTyThing.hs index e57122b721..0609660285 100644 --- a/compiler/main/PprTyThing.hs +++ b/compiler/main/PprTyThing.hs @@ -27,6 +27,7 @@ import TcType import Var import Name import Outputable +import FastString -- ----------------------------------------------------------------------------- -- Pretty-printing entities that we get from the GHC API diff --git a/compiler/main/StaticFlags.hs b/compiler/main/StaticFlags.hs index 7200c35dca..a2362d91e5 100644 --- a/compiler/main/StaticFlags.hs +++ b/compiler/main/StaticFlags.hs @@ -75,7 +75,7 @@ module StaticFlags ( import CmdLineParser import Config -import FastString ( FastString, mkFastString ) +import FastString import Util import Maybes ( firstJust ) import Panic diff --git a/compiler/main/SysTools.lhs b/compiler/main/SysTools.lhs index 576c3fc1f1..97a5ea7bf6 100644 --- a/compiler/main/SysTools.lhs +++ b/compiler/main/SysTools.lhs @@ -74,7 +74,7 @@ import CString ( CString, peekCString ) import System.Process ( runInteractiveProcess, getProcessExitCode ) import Control.Concurrent( forkIO, newChan, readChan, writeChan ) -import FastString ( mkFastString ) +import FastString import SrcLoc ( SrcLoc, mkSrcLoc, noSrcSpan, mkSrcSpan ) \end{code} diff --git a/compiler/main/TidyPgm.lhs b/compiler/main/TidyPgm.lhs index ca021222da..64f3498ad4 100644 --- a/compiler/main/TidyPgm.lhs +++ b/compiler/main/TidyPgm.lhs @@ -45,9 +45,6 @@ import FastBool hiding ( fastOr ) import Data.List ( partition ) import Data.Maybe ( isJust ) import Data.IORef ( IORef, readIORef, writeIORef ) - -_dummy :: FS.FastString -_dummy = FSLIT("") \end{code} diff --git a/compiler/nativeGen/PositionIndependentCode.hs b/compiler/nativeGen/PositionIndependentCode.hs index 7d13f114e2..8cd797d84b 100644 --- a/compiler/nativeGen/PositionIndependentCode.hs +++ b/compiler/nativeGen/PositionIndependentCode.hs @@ -76,6 +76,7 @@ import qualified Outputable import Panic ( panic ) import DynFlags +import FastString -- The most important function here is cmmMakeDynamicReference. diff --git a/compiler/nativeGen/RegAllocLinear.hs b/compiler/nativeGen/RegAllocLinear.hs index 4b023c5e76..14d7eba5a4 100644 --- a/compiler/nativeGen/RegAllocLinear.hs +++ b/compiler/nativeGen/RegAllocLinear.hs @@ -101,6 +101,7 @@ import UniqFM import UniqSupply import Outputable import State +import FastString import Data.Maybe import Data.List diff --git a/compiler/nativeGen/RegLiveness.hs b/compiler/nativeGen/RegLiveness.hs index 9ee98971ba..6bee0c85fc 100644 --- a/compiler/nativeGen/RegLiveness.hs +++ b/compiler/nativeGen/RegLiveness.hs @@ -46,6 +46,7 @@ import UniqFM import UniqSupply import Bag import State +import FastString import Data.List import Data.Maybe diff --git a/compiler/prelude/ForeignCall.lhs b/compiler/prelude/ForeignCall.lhs index e97a2415d0..50130785cd 100644 --- a/compiler/prelude/ForeignCall.lhs +++ b/compiler/prelude/ForeignCall.lhs @@ -26,7 +26,7 @@ module ForeignCall ( #include "HsVersions.h" -import FastString ( FastString, unpackFS ) +import FastString import Char ( isAlphaNum ) import Binary import Outputable diff --git a/compiler/prelude/TysPrim.lhs b/compiler/prelude/TysPrim.lhs index 9aa837d3b4..6b02116222 100644 --- a/compiler/prelude/TysPrim.lhs +++ b/compiler/prelude/TysPrim.lhs @@ -68,7 +68,7 @@ import SrcLoc import Unique ( mkAlphaTyVarUnique, pprUnique ) import PrelNames import StaticFlags -import FastString ( FastString, mkFastString ) +import FastString import Outputable import Char ( ord, chr ) diff --git a/compiler/profiling/SCCfinal.lhs b/compiler/profiling/SCCfinal.lhs index e4d199ccd6..a254a08a38 100644 --- a/compiler/profiling/SCCfinal.lhs +++ b/compiler/profiling/SCCfinal.lhs @@ -25,8 +25,6 @@ This is now a sort-of-normal STG-to-STG pass (WDP 94/06), run by stg2stg. \begin{code} module SCCfinal ( stgMassageForProfiling ) where --- XXX This define is a bit of a hack, and should be done more nicely -#define FAST_STRING_NOT_NEEDED 1 #include "HsVersions.h" import StgSyn diff --git a/compiler/rename/RnBinds.lhs b/compiler/rename/RnBinds.lhs index 638e9554a9..e27be3df77 100644 --- a/compiler/rename/RnBinds.lhs +++ b/compiler/rename/RnBinds.lhs @@ -60,6 +60,7 @@ import BasicTypes ( RecFlag(..) ) import Digraph ( SCC(..), stronglyConnComp ) import Bag import Outputable +import FastString import Maybes ( orElse ) import Util ( filterOut ) import Monad ( foldM, unless ) diff --git a/compiler/rename/RnNames.lhs b/compiler/rename/RnNames.lhs index b9e491e461..d01c5b7de2 100644 --- a/compiler/rename/RnNames.lhs +++ b/compiler/rename/RnNames.lhs @@ -49,6 +49,7 @@ import ErrUtils import BasicTypes ( DeprecTxt, Fixity ) import DriverPhases ( isHsBoot ) import Util +import FastString import ListSetOps import Data.List ( partition, concatMap, (\\), delete ) import IO ( openFile, IOMode(..) ) diff --git a/compiler/rename/RnSource.lhs b/compiler/rename/RnSource.lhs index 741440ffe2..70c995748c 100644 --- a/compiler/rename/RnSource.lhs +++ b/compiler/rename/RnSource.lhs @@ -49,6 +49,7 @@ import NameEnv import LazyUniqFM import OccName import Outputable +import FastString import SrcLoc ( Located(..), unLoc, noLoc ) import DynFlags ( DynFlag(..) ) import Maybe ( isNothing ) diff --git a/compiler/rename/RnTypes.lhs b/compiler/rename/RnTypes.lhs index 3de4345458..0e58a59794 100644 --- a/compiler/rename/RnTypes.lhs +++ b/compiler/rename/RnTypes.lhs @@ -31,6 +31,7 @@ import NameSet import BasicTypes ( compareFixity, funTyFixity, negateFixity, Fixity(..), FixityDirection(..) ) import Outputable +import FastString #include "HsVersions.h" \end{code} diff --git a/compiler/simplCore/CSE.lhs b/compiler/simplCore/CSE.lhs index 93b0b8dd60..38c1f58ee5 100644 --- a/compiler/simplCore/CSE.lhs +++ b/compiler/simplCore/CSE.lhs @@ -23,6 +23,7 @@ import StaticFlags ( opt_PprStyle_Debug ) import BasicTypes ( isAlwaysActive ) import Util ( lengthExceeds ) import UniqFM +import FastString import Data.List \end{code} diff --git a/compiler/simplCore/FloatOut.lhs b/compiler/simplCore/FloatOut.lhs index e6e8b7a015..41797746e1 100644 --- a/compiler/simplCore/FloatOut.lhs +++ b/compiler/simplCore/FloatOut.lhs @@ -31,6 +31,7 @@ import SetLevels ( Level(..), LevelledExpr, LevelledBind, import UniqSupply ( UniqSupply ) import List ( partition ) import Outputable +import FastString \end{code} ----------------- diff --git a/compiler/simplCore/OccurAnal.lhs b/compiler/simplCore/OccurAnal.lhs index 7c7cf89d41..794217f76f 100644 --- a/compiler/simplCore/OccurAnal.lhs +++ b/compiler/simplCore/OccurAnal.lhs @@ -15,8 +15,6 @@ module OccurAnal ( occurAnalysePgm, occurAnalyseExpr ) where --- XXX This define is a bit of a hack, and should be done more nicely -#define FAST_STRING_NOT_NEEDED 1 #include "HsVersions.h" import CoreSyn diff --git a/compiler/simplCore/SimplEnv.lhs b/compiler/simplCore/SimplEnv.lhs index 462a697da3..699ba7be15 100644 --- a/compiler/simplCore/SimplEnv.lhs +++ b/compiler/simplCore/SimplEnv.lhs @@ -66,6 +66,7 @@ import DynFlags import Util import MonadUtils import Outputable +import FastString import Data.List \end{code} diff --git a/compiler/simplCore/SimplMonad.lhs b/compiler/simplCore/SimplMonad.lhs index d914ef3bdc..ea5ce12ba7 100644 --- a/compiler/simplCore/SimplMonad.lhs +++ b/compiler/simplCore/SimplMonad.lhs @@ -43,7 +43,7 @@ import StaticFlags ( opt_PprStyle_Debug, opt_HistorySize ) import Unique ( Unique ) import Maybes ( expectJust ) import FiniteMap ( FiniteMap, emptyFM, isEmptyFM, lookupFM, addToFM, plusFM_C, fmToList ) -import FastString ( FastString ) +import FastString import Outputable import FastTypes diff --git a/compiler/simplCore/SimplUtils.lhs b/compiler/simplCore/SimplUtils.lhs index 060d346bd3..6d2250550e 100644 --- a/compiler/simplCore/SimplUtils.lhs +++ b/compiler/simplCore/SimplUtils.lhs @@ -58,6 +58,7 @@ import BasicTypes import Util import MonadUtils import Outputable +import FastString import List( nub ) \end{code} diff --git a/compiler/simplCore/Simplify.lhs b/compiler/simplCore/Simplify.lhs index d41de74fb5..27d2c541dd 100644 --- a/compiler/simplCore/Simplify.lhs +++ b/compiler/simplCore/Simplify.lhs @@ -34,6 +34,7 @@ import BasicTypes ( TopLevelFlag(..), isTopLevel, import Maybes ( orElse ) import Data.List ( mapAccumL ) import Outputable +import FastString \end{code} diff --git a/compiler/simplStg/SRT.lhs b/compiler/simplStg/SRT.lhs index 1a17c06228..989fa4c1f8 100644 --- a/compiler/simplStg/SRT.lhs +++ b/compiler/simplStg/SRT.lhs @@ -16,8 +16,6 @@ bindings have no CAF references, and record the fact in their IdInfo. module SRT( computeSRTs ) where --- XXX This define is a bit of a hack, and should be done more nicely -#define FAST_STRING_NOT_NEEDED 1 #include "HsVersions.h" import StgSyn diff --git a/compiler/simplStg/SimplStg.lhs b/compiler/simplStg/SimplStg.lhs index e0d13c6770..e31415b2f5 100644 --- a/compiler/simplStg/SimplStg.lhs +++ b/compiler/simplStg/SimplStg.lhs @@ -6,8 +6,6 @@ \begin{code} module SimplStg ( stg2stg ) where --- XXX This define is a bit of a hack, and should be done more nicely -#define FAST_STRING_NOT_NEEDED 1 #include "HsVersions.h" import StgSyn diff --git a/compiler/simplStg/StgStats.lhs b/compiler/simplStg/StgStats.lhs index bca2bbb13b..25c988d52b 100644 --- a/compiler/simplStg/StgStats.lhs +++ b/compiler/simplStg/StgStats.lhs @@ -30,8 +30,6 @@ The program gather statistics about module StgStats ( showStgStats ) where --- XXX This define is a bit of a hack, and should be done more nicely -#define FAST_STRING_NOT_NEEDED 1 #include "HsVersions.h" import StgSyn diff --git a/compiler/stgSyn/CoreToStg.lhs b/compiler/stgSyn/CoreToStg.lhs index d03412ad3d..dbb785bed4 100644 --- a/compiler/stgSyn/CoreToStg.lhs +++ b/compiler/stgSyn/CoreToStg.lhs @@ -39,6 +39,7 @@ import StaticFlags ( opt_RuntimeTypes ) import Module import Outputable import MonadUtils +import FastString import Util \end{code} diff --git a/compiler/stgSyn/StgLint.lhs b/compiler/stgSyn/StgLint.lhs index 9dc83cd863..23e8f3b39a 100644 --- a/compiler/stgSyn/StgLint.lhs +++ b/compiler/stgSyn/StgLint.lhs @@ -34,6 +34,7 @@ import TyCon ( isAlgTyCon, isNewTyCon, tyConDataCons ) import Util ( zipEqual, equalLength ) import SrcLoc ( srcLocSpan ) import Outputable +import FastString import Control.Monad \end{code} diff --git a/compiler/stgSyn/StgSyn.lhs b/compiler/stgSyn/StgSyn.lhs index 893358b8cd..42bcabb9c2 100644 --- a/compiler/stgSyn/StgSyn.lhs +++ b/compiler/stgSyn/StgSyn.lhs @@ -67,6 +67,7 @@ import Unique ( Unique ) import Bitmap import StaticFlags ( opt_SccProfilingOn ) import Module +import FastString \end{code} %************************************************************************ diff --git a/compiler/stranal/WwLib.lhs b/compiler/stranal/WwLib.lhs index 5f63a481bf..4254d35de8 100644 --- a/compiler/stranal/WwLib.lhs +++ b/compiler/stranal/WwLib.lhs @@ -28,6 +28,7 @@ import UniqSupply import Unique import Util ( zipWithEqual, notNull ) import Outputable +import FastString import List ( zipWith4 ) \end{code} diff --git a/compiler/typecheck/FamInst.lhs b/compiler/typecheck/FamInst.lhs index ca5a7e9084..224a9601b8 100644 --- a/compiler/typecheck/FamInst.lhs +++ b/compiler/typecheck/FamInst.lhs @@ -27,6 +27,7 @@ import SrcLoc import Outputable import LazyUniqFM import FiniteMap +import FastString import Maybe import Monad diff --git a/compiler/typecheck/Inst.lhs b/compiler/typecheck/Inst.lhs index d507bddb1b..91e409fe28 100644 --- a/compiler/typecheck/Inst.lhs +++ b/compiler/typecheck/Inst.lhs @@ -60,7 +60,7 @@ module Inst ( import {-# SOURCE #-} TcExpr( tcPolyExpr ) import {-# SOURCE #-} TcUnify( boxyUnify, unifyType ) -import FastString(FastString) +import FastString import HsSyn import TcHsSyn import TcRnMonad diff --git a/compiler/typecheck/TcArrows.lhs b/compiler/typecheck/TcArrows.lhs index 90a5e885e3..11daed77da 100644 --- a/compiler/typecheck/TcArrows.lhs +++ b/compiler/typecheck/TcArrows.lhs @@ -40,6 +40,7 @@ import Type import SrcLoc import Outputable +import FastString import Util import Control.Monad diff --git a/compiler/typecheck/TcBinds.lhs b/compiler/typecheck/TcBinds.lhs index e3bd6575fd..d9f55874c0 100644 --- a/compiler/typecheck/TcBinds.lhs +++ b/compiler/typecheck/TcBinds.lhs @@ -56,6 +56,7 @@ import List import Util import BasicTypes import Outputable +import FastString import Control.Monad \end{code} diff --git a/compiler/typecheck/TcDefaults.lhs b/compiler/typecheck/TcDefaults.lhs index 9da5d96fb5..ad5e9b86a6 100644 --- a/compiler/typecheck/TcDefaults.lhs +++ b/compiler/typecheck/TcDefaults.lhs @@ -29,6 +29,7 @@ import DynFlags import SrcLoc import Maybe import Outputable +import FastString \end{code} \begin{code} diff --git a/compiler/typecheck/TcDeriv.lhs b/compiler/typecheck/TcDeriv.lhs index 7422c6fa99..2edd836105 100644 --- a/compiler/typecheck/TcDeriv.lhs +++ b/compiler/typecheck/TcDeriv.lhs @@ -46,6 +46,7 @@ import SrcLoc import Util import ListSetOps import Outputable +import FastString import Bag \end{code} diff --git a/compiler/typecheck/TcEnv.lhs b/compiler/typecheck/TcEnv.lhs index ad45c7ca4c..aa27a43c88 100644 --- a/compiler/typecheck/TcEnv.lhs +++ b/compiler/typecheck/TcEnv.lhs @@ -81,6 +81,7 @@ import HscTypes import SrcLoc import Outputable import Maybes +import FastString \end{code} diff --git a/compiler/typecheck/TcForeign.lhs b/compiler/typecheck/TcForeign.lhs index dc6220661a..0353f1f43d 100644 --- a/compiler/typecheck/TcForeign.lhs +++ b/compiler/typecheck/TcForeign.lhs @@ -49,6 +49,7 @@ import Outputable import SrcLoc import Bag import Unique +import FastString \end{code} \begin{code} diff --git a/compiler/typecheck/TcGadt.lhs b/compiler/typecheck/TcGadt.lhs index 48b2b0623c..e45d6bd53a 100644 --- a/compiler/typecheck/TcGadt.lhs +++ b/compiler/typecheck/TcGadt.lhs @@ -41,6 +41,7 @@ import Outputable import TcType import Unique import UniqFM +import FastString \end{code} diff --git a/compiler/typecheck/TcHsSyn.lhs b/compiler/typecheck/TcHsSyn.lhs index 7bb1d5e38d..7afd9e8501 100644 --- a/compiler/typecheck/TcHsSyn.lhs +++ b/compiler/typecheck/TcHsSyn.lhs @@ -57,6 +57,7 @@ import SrcLoc import Util import Bag import Outputable +import FastString \end{code} \begin{code} diff --git a/compiler/typecheck/TcHsType.lhs b/compiler/typecheck/TcHsType.lhs index 66102a64df..08f4f7f718 100644 --- a/compiler/typecheck/TcHsType.lhs +++ b/compiler/typecheck/TcHsType.lhs @@ -53,6 +53,7 @@ import BasicTypes import SrcLoc import UniqSupply import Outputable +import FastString import Control.Monad \end{code} diff --git a/compiler/typecheck/TcMType.lhs b/compiler/typecheck/TcMType.lhs index 30917eff83..fc434d897f 100644 --- a/compiler/typecheck/TcMType.lhs +++ b/compiler/typecheck/TcMType.lhs @@ -88,6 +88,7 @@ import ListSetOps import UniqSupply import SrcLoc import Outputable +import FastString import Control.Monad ( when, unless ) import Data.List ( (\\) ) diff --git a/compiler/typecheck/TcMatches.lhs b/compiler/typecheck/TcMatches.lhs index b7262d6bf3..5826eb9f1f 100644 --- a/compiler/typecheck/TcMatches.lhs +++ b/compiler/typecheck/TcMatches.lhs @@ -42,6 +42,7 @@ import TysPrim import Outputable import Util import SrcLoc +import FastString import Control.Monad \end{code} diff --git a/compiler/typecheck/TcRnTypes.lhs b/compiler/typecheck/TcRnTypes.lhs index 98bb936b50..a33faa1691 100644 --- a/compiler/typecheck/TcRnTypes.lhs +++ b/compiler/typecheck/TcRnTypes.lhs @@ -74,6 +74,7 @@ import Bag import Outputable import ListSetOps import FiniteMap +import FastString import Data.Maybe import Data.List diff --git a/compiler/typecheck/TcRules.lhs b/compiler/typecheck/TcRules.lhs index a0774fed62..50ad098e1e 100644 --- a/compiler/typecheck/TcRules.lhs +++ b/compiler/typecheck/TcRules.lhs @@ -30,6 +30,7 @@ import Id import Name import SrcLoc import Outputable +import FastString \end{code} \begin{code} diff --git a/compiler/typecheck/TcSimplify.lhs b/compiler/typecheck/TcSimplify.lhs index 63529c12c1..a5ce732331 100644 --- a/compiler/typecheck/TcSimplify.lhs +++ b/compiler/typecheck/TcSimplify.lhs @@ -64,6 +64,7 @@ import Util import UniqSet import SrcLoc import DynFlags +import FastString import Control.Monad import Data.List diff --git a/compiler/typecheck/TcTyClsDecls.lhs b/compiler/typecheck/TcTyClsDecls.lhs index 054f58b4dc..12fb28d7ae 100644 --- a/compiler/typecheck/TcTyClsDecls.lhs +++ b/compiler/typecheck/TcTyClsDecls.lhs @@ -51,6 +51,7 @@ import SrcLoc import ListSetOps import Digraph import DynFlags +import FastString import Data.List import Control.Monad ( mplus ) diff --git a/compiler/typecheck/TcTyFuns.lhs b/compiler/typecheck/TcTyFuns.lhs index 36ff1bbb3e..625d4cdd72 100644 --- a/compiler/typecheck/TcTyFuns.lhs +++ b/compiler/typecheck/TcTyFuns.lhs @@ -35,6 +35,7 @@ import Bag import Outputable import SrcLoc ( Located(..) ) import Maybes +import FastString -- standard import Data.List diff --git a/compiler/typecheck/TcType.lhs b/compiler/typecheck/TcType.lhs index c263660f4a..95d8deb964 100644 --- a/compiler/typecheck/TcType.lhs +++ b/compiler/typecheck/TcType.lhs @@ -165,6 +165,7 @@ import Util import Maybes import ListSetOps import Outputable +import FastString import Data.List import Data.IORef diff --git a/compiler/typecheck/TcUnify.lhs b/compiler/typecheck/TcUnify.lhs index 4aa9b3d3c4..d7399f5cd3 100644 --- a/compiler/typecheck/TcUnify.lhs +++ b/compiler/typecheck/TcUnify.lhs @@ -60,6 +60,7 @@ import BasicTypes import Util import Outputable import Unique +import FastString import Control.Monad \end{code} diff --git a/compiler/types/Class.lhs b/compiler/types/Class.lhs index 051bef165c..2f946d8592 100644 --- a/compiler/types/Class.lhs +++ b/compiler/types/Class.lhs @@ -27,6 +27,7 @@ import Name import BasicTypes import Unique import Outputable +import FastString \end{code} %************************************************************************ diff --git a/compiler/types/Coercion.lhs b/compiler/types/Coercion.lhs index 9ebd00e760..674e2a70bd 100644 --- a/compiler/types/Coercion.lhs +++ b/compiler/types/Coercion.lhs @@ -70,7 +70,7 @@ import Util import Unique import BasicTypes import Outputable - +import FastString type Coercion = Type type CoercionKind = Kind -- A CoercionKind is always of form (ty1 :=: ty2) @@ -438,7 +438,7 @@ unsafeCoercionTyCon -------------------------------------- -- ...and their names -mkCoConName :: FS.FastString -> Unique -> TyCon -> Name +mkCoConName :: FastString -> Unique -> TyCon -> Name mkCoConName occ key coCon = mkWiredInName gHC_PRIM (mkOccNameFS tcName occ) key (ATyCon coCon) BuiltInSyntax diff --git a/compiler/types/FamInstEnv.lhs b/compiler/types/FamInstEnv.lhs index 3bfe55d1f0..396c844047 100644 --- a/compiler/types/FamInstEnv.lhs +++ b/compiler/types/FamInstEnv.lhs @@ -37,6 +37,7 @@ import UniqFM import Outputable import Maybes import Util +import FastString import Maybe \end{code} diff --git a/compiler/types/FunDeps.lhs b/compiler/types/FunDeps.lhs index ac5c0a0b1e..26c0d68e92 100644 --- a/compiler/types/FunDeps.lhs +++ b/compiler/types/FunDeps.lhs @@ -27,6 +27,8 @@ import VarSet import VarEnv import Outputable import Util +import FastString + import Data.Maybe ( isJust ) \end{code} diff --git a/compiler/types/InstEnv.lhs b/compiler/types/InstEnv.lhs index 8fd3d83244..68a86aab25 100644 --- a/compiler/types/InstEnv.lhs +++ b/compiler/types/InstEnv.lhs @@ -33,6 +33,7 @@ import Outputable import BasicTypes import UniqFM import Id +import FastString import Data.Maybe ( isJust, isNothing ) \end{code} diff --git a/compiler/types/Type.lhs b/compiler/types/Type.lhs index d5c00e8070..686bba849f 100644 --- a/compiler/types/Type.lhs +++ b/compiler/types/Type.lhs @@ -130,6 +130,7 @@ import TyCon import StaticFlags import Util import Outputable +import FastString import Data.List import Data.Maybe ( isJust ) diff --git a/compiler/types/Unify.lhs b/compiler/types/Unify.lhs index 63c64f07a1..63089b603e 100644 --- a/compiler/types/Unify.lhs +++ b/compiler/types/Unify.lhs @@ -13,8 +13,6 @@ module Unify ( dataConCannotMatch ) where --- XXX This define is a bit of a hack, and should be done more nicely -#define FAST_STRING_NOT_NEEDED 1 #include "HsVersions.h" import Var diff --git a/compiler/utils/Digraph.lhs b/compiler/utils/Digraph.lhs index c36e7058fc..6d1d8d4639 100644 --- a/compiler/utils/Digraph.lhs +++ b/compiler/utils/Digraph.lhs @@ -24,8 +24,6 @@ module Digraph( bcc ) where --- XXX This define is a bit of a hack, and should be done more nicely -#define FAST_STRING_NOT_NEEDED 1 #include "HsVersions.h" ------------------------------------------------------------------------------ diff --git a/compiler/utils/Encoding.hs b/compiler/utils/Encoding.hs index 2943768d56..f2659e6a9a 100644 --- a/compiler/utils/Encoding.hs +++ b/compiler/utils/Encoding.hs @@ -23,7 +23,6 @@ module Encoding ( zDecodeString ) where -#define COMPILING_FAST_STRING #include "HsVersions.h" import Foreign import Data.Char ( ord, chr, isDigit, digitToInt, intToDigit, diff --git a/compiler/utils/FastFunctions.lhs b/compiler/utils/FastFunctions.lhs index 5d8ff23dbd..aca5344bc8 100644 --- a/compiler/utils/FastFunctions.lhs +++ b/compiler/utils/FastFunctions.lhs @@ -12,7 +12,6 @@ module FastFunctions ( global, Global ) where -#define COMPILING_FAST_STRING #include "HsVersions.h" import FastTypes diff --git a/compiler/utils/FastString.lhs b/compiler/utils/FastString.lhs index 2448f1686d..4417c0850f 100644 --- a/compiler/utils/FastString.lhs +++ b/compiler/utils/FastString.lhs @@ -71,9 +71,6 @@ module FastString ptrStrLength ) where --- This #define suppresses the "import FastString" that --- HsVersions otherwise produces -#define COMPILING_FAST_STRING #include "HsVersions.h" import Encoding diff --git a/compiler/utils/FastTypes.lhs b/compiler/utils/FastTypes.lhs index 71a317b1c9..a69ab25671 100644 --- a/compiler/utils/FastTypes.lhs +++ b/compiler/utils/FastTypes.lhs @@ -39,7 +39,6 @@ module FastTypes ( FastPtr, pBox, pUnbox, castFastPtr ) where -#define COMPILING_FAST_STRING #include "HsVersions.h" #if defined(__GLASGOW_HASKELL__) diff --git a/compiler/utils/Interval.hs b/compiler/utils/Interval.hs index 8d96b19c7d..03545ebc40 100644 --- a/compiler/utils/Interval.hs +++ b/compiler/utils/Interval.hs @@ -111,6 +111,6 @@ rev_app :: [a] -> [a] -> [a] rev_app [] xs = xs rev_app (y:ys) xs = rev_app ys (y:xs) - -_unused :: FS.FastString +_unused :: () _unused = undefined i_min i_lim overlaps contains + diff --git a/compiler/utils/Panic.lhs b/compiler/utils/Panic.lhs index ffd3b6751d..f79ffce783 100644 --- a/compiler/utils/Panic.lhs +++ b/compiler/utils/Panic.lhs @@ -22,8 +22,6 @@ module Panic installSignalHandlers, interruptTargetThread ) where --- XXX This define is a bit of a hack, and should be done more nicely -#define FAST_STRING_NOT_NEEDED 1 #include "HsVersions.h" import Config diff --git a/compiler/utils/UniqFM.lhs b/compiler/utils/UniqFM.lhs index 862ca589d8..4081017f87 100644 --- a/compiler/utils/UniqFM.lhs +++ b/compiler/utils/UniqFM.lhs @@ -839,7 +839,3 @@ use_snd :: a -> b -> b use_snd _ b = b \end{code} -\begin{code} -_unused :: FS.FastString -_unused = undefined -\end{code} diff --git a/compiler/utils/Util.lhs b/compiler/utils/Util.lhs index 9537ae1f37..1d11b90a55 100644 --- a/compiler/utils/Util.lhs +++ b/compiler/utils/Util.lhs @@ -74,8 +74,6 @@ module Util ( Direction(..), reslash, ) where --- XXX This define is a bit of a hack, and should be done more nicely -#define FAST_STRING_NOT_NEEDED 1 #include "HsVersions.h" import Panic diff --git a/compiler/vectorise/VectCore.hs b/compiler/vectorise/VectCore.hs index 34ffdb7cae..de832793f6 100644 --- a/compiler/vectorise/VectCore.hs +++ b/compiler/vectorise/VectCore.hs @@ -11,8 +11,6 @@ module VectCore ( vCaseDEFAULT, vCaseProd ) where --- XXX This define is a bit of a hack, and should be done more nicely -#define FAST_STRING_NOT_NEEDED 1 #include "HsVersions.h" import CoreSyn diff --git a/compiler/vectorise/VectType.hs b/compiler/vectorise/VectType.hs index 86dcaf236b..cfcea389bb 100644 --- a/compiler/vectorise/VectType.hs +++ b/compiler/vectorise/VectType.hs @@ -45,6 +45,7 @@ import Util ( singleton ) import Digraph ( SCC(..), stronglyConnComp ) import Outputable +import FastString import Control.Monad ( liftM, liftM2, zipWithM, zipWithM_, mapAndUnzipM ) import Data.List ( inits, tails, zipWith4, zipWith5 ) |