ghc-8.0.2: The GHC API

Safe HaskellNone
LanguageHaskell2010

RtClosureInspect

Synopsis

Documentation

cvObtainTerm :: HscEnv -> Int -> Bool -> RttiType -> HValue -> IO Term #

cvReconstructType :: HscEnv -> Int -> GhciType -> HValue -> IO (Maybe Type) #

improveRTTIType :: HscEnv -> RttiType -> RttiType -> Maybe TCvSubst #

data Term #

Constructors

Term 

Fields

Prim 

Fields

Suspension 

Fields

NewtypeWrap 

Fields

RefWrap 

Fields

Instances

Outputable Term # 

Methods

ppr :: Term -> SDoc #

pprPrec :: Rational -> Term -> SDoc #

termType :: Term -> RttiType #

mapTermType :: (RttiType -> Type) -> Term -> Term #

foldTerm :: TermFold a -> Term -> a #

data TermFold a #

Constructors

TermFold 

Fields

foldTermM :: Monad m => TermFoldM m a -> Term -> m a #

data TermFoldM m a #

Constructors

TermFoldM 

Fields

pprTerm :: TermPrinter -> TermPrinter #

cPprTerm :: Monad m => CustomTermPrinter m -> Term -> m SDoc #

Takes a list of custom printers with a explicit recursion knot and a term, and returns the output of the first successful printer, or the default printer

type CustomTermPrinter m = TermPrinterM m -> [Precedence -> Term -> m (Maybe SDoc)] #

data Closure #

Constructors

Closure