ghc-6.12.2: The GHC APISource codeContentsIndex
SimplMonad
Synopsis
data SimplM result
initSmpl :: DynFlags -> RuleBase -> (FamInstEnv, FamInstEnv) -> UniqSupply -> SimplM a -> (a, SimplCount)
getDOptsSmpl :: SimplM DynFlags
getSimplRules :: SimplM RuleBase
getFamEnvs :: SimplM (FamInstEnv, FamInstEnv)
class Monad m => MonadUnique m where
getUniqueSupplyM :: m UniqSupply
getUniqueM :: m Unique
getUniquesM :: m [Unique]
newId :: FastString -> Type -> SimplM Id
data SimplCount
data Tick
= PreInlineUnconditionally Id
| PostInlineUnconditionally Id
| UnfoldingDone Id
| RuleFired FastString
| LetFloatFromLet
| EtaExpansion Id
| EtaReduction Id
| BetaReduction Id
| CaseOfCase Id
| KnownBranch Id
| CaseMerge Id
| AltMerge Id
| CaseElim Id
| CaseIdentity Id
| FillInCaseDefault Id
| BottomFound
| SimplifierDone
tick :: Tick -> SimplM ()
freeTick :: Tick -> SimplM ()
getSimplCount :: SimplM SimplCount
zeroSimplCount :: DynFlags -> SimplCount
pprSimplCount :: SimplCount -> SDoc
plusSimplCount :: SimplCount -> SimplCount -> SimplCount
isZeroSimplCount :: SimplCount -> Bool
type SwitchChecker = SimplifierSwitch -> SwitchResult
data SwitchResult
= SwBool Bool
| SwString FastString
| SwInt Int
getSimplIntSwitch :: SwitchChecker -> (Int -> SimplifierSwitch) -> Int
isAmongSimpl :: [SimplifierSwitch] -> SimplifierSwitch -> SwitchResult
intSwitchSet :: (switch -> SwitchResult) -> (Int -> switch) -> Maybe Int
switchIsOn :: (switch -> SwitchResult) -> switch -> Bool
Documentation
data SimplM result Source
show/hide Instances
initSmpl :: DynFlags -> RuleBase -> (FamInstEnv, FamInstEnv) -> UniqSupply -> SimplM a -> (a, SimplCount)Source
getDOptsSmpl :: SimplM DynFlagsSource
getSimplRules :: SimplM RuleBaseSource
getFamEnvs :: SimplM (FamInstEnv, FamInstEnv)Source
class Monad m => MonadUnique m whereSource
A monad for generating unique identifiers
Methods
getUniqueSupplyM :: m UniqSupplySource
Get a new UniqueSupply
getUniqueM :: m UniqueSource
Get a new unique identifier
getUniquesM :: m [Unique]Source
Get an infinite list of new unique identifiers
show/hide Instances
newId :: FastString -> Type -> SimplM IdSource
data SimplCount Source
data Tick Source
Constructors
PreInlineUnconditionally Id
PostInlineUnconditionally Id
UnfoldingDone Id
RuleFired FastString
LetFloatFromLet
EtaExpansion Id
EtaReduction Id
BetaReduction Id
CaseOfCase Id
KnownBranch Id
CaseMerge Id
AltMerge Id
CaseElim Id
CaseIdentity Id
FillInCaseDefault Id
BottomFound
SimplifierDone
show/hide Instances
tick :: Tick -> SimplM ()Source
freeTick :: Tick -> SimplM ()Source
getSimplCount :: SimplM SimplCountSource
zeroSimplCount :: DynFlags -> SimplCountSource
pprSimplCount :: SimplCount -> SDocSource
plusSimplCount :: SimplCount -> SimplCount -> SimplCountSource
isZeroSimplCount :: SimplCount -> BoolSource
type SwitchChecker = SimplifierSwitch -> SwitchResultSource
data SwitchResult Source
Constructors
SwBool Bool
SwString FastString
SwInt Int
getSimplIntSwitch :: SwitchChecker -> (Int -> SimplifierSwitch) -> IntSource
isAmongSimpl :: [SimplifierSwitch] -> SimplifierSwitch -> SwitchResultSource
intSwitchSet :: (switch -> SwitchResult) -> (Int -> switch) -> Maybe IntSource
switchIsOn :: (switch -> SwitchResult) -> switch -> BoolSource
Produced by Haddock version 2.6.1