ghc-7.8.2: The GHC API

Safe Haskell | None
Language | Haskell98

NCGMonad

# Documentation

data NatM_State

Constructors

NatM_State |
Fields natm_us :: UniqSupply natm_delta :: Int natm_imports :: [CLabel] natm_pic :: Maybe Reg natm_dflags :: DynFlags natm_this_module :: Module

mkNatM_State :: UniqSupply -> Int -> DynFlags -> Module -> NatM_State

data NatM result

Instances

Monad NatM |
Functor NatM |
Applicative NatM |
HasDynFlags NatM |
CmmMakeDynamicReferenceM NatM |

initNat :: NatM_State -> NatM a -> (a, NatM_State)

addImportNat :: CLabel -> NatM ()

getUniqueNat :: NatM Unique

mapAccumLNat :: (acc -> x -> NatM (acc, y)) -> acc -> [x] -> NatM (acc, [y])

setDeltaNat :: Int -> NatM ()

getDeltaNat :: NatM Int

getThisModuleNat :: NatM Module

getBlockIdNat :: NatM BlockId

getNewLabelNat :: NatM CLabel

getNewRegNat :: Size -> NatM Reg

getNewRegPairNat :: Size -> NatM (Reg, Reg)

getPicBaseMaybeNat :: NatM (Maybe Reg)

getPicBaseNat :: Size -> NatM Reg

getDynFlags :: HasDynFlags m => m DynFlags