Safe Haskell | None |
---|---|
Language | Haskell2010 |
Synopsis
- data Unique = Unique !Char !Int
- data ExternalName
- = ExternalName { }
- | ForeignCall
- newtype BinderId = BinderId Unique
- newtype SBinder = SBndr {}
- newtype Binder = Bndr {}
- binderUniqueName :: Binder -> Text
- data Binder' bndr var
- = Binder {
- binderName :: !Text
- binderId :: !BinderId
- binderIdInfo :: IdInfo bndr var
- binderIdDetails :: IdDetails
- binderType :: Type' bndr var
- | TyBinder {
- binderName :: !Text
- binderId :: !BinderId
- binderKind :: Type' bndr var
- = Binder {
- data IdInfo bndr var = IdInfo {
- idiArity :: !Int
- idiIsOneShot :: Bool
- idiUnfolding :: Unfolding bndr var
- idiInlinePragma :: !Text
- idiOccInfo :: OccInfo
- idiStrictnessSig :: !Text
- idiDemandSig :: !Text
- idiCallArity :: !Int
- data Unfolding bndr var
- = NoUnfolding
- | BootUnfolding
- | OtherCon [AltCon]
- | DFunUnfolding
- | CoreUnfolding {
- unfTemplate :: Expr' bndr var
- unfIsValue :: Bool
- unfIsConLike :: Bool
- unfIsWorkFree :: Bool
- unfGuidance :: Text
- data OccInfo
- = OccManyOccs
- | OccDead
- | OccOneOcc
- | OccLoopBreaker { }
- data IdDetails
- = VanillaId
- | RecSelId
- | DataConWorkId
- | DataConWrapId
- | ClassOpId
- | PrimOpId
- | TickBoxOpId
- | DFunId
- | CoVarId
- | JoinId {
- joinIdArity :: !Int
- data Lit
- data TyCon = TyCon !Text !Unique
- type SType = Type' SBinder BinderId
- type Type = Type' Binder Binder
- data Type' bndr var
- newtype ModuleName = ModuleName {}
- type Module = Module' Binder Binder
- type SModule = Module' SBinder BinderId
- data Module' bndr var = Module {
- moduleName :: ModuleName
- modulePhase :: Text
- moduleTopBindings :: [TopBinding' bndr var]
- moduleBindings :: Module' bndr var -> [(bndr, CoreStats, Expr' bndr var)]
- type SExpr = Expr' SBinder BinderId
- type Expr = Expr' Binder Binder
- data Expr' bndr var
- type SAlt = Alt' SBinder BinderId
- type Alt = Alt' Binder Binder
- data Alt' bndr var = Alt {
- altCon :: !AltCon
- altBinders :: [bndr]
- altRHS :: Expr' bndr var
- data AltCon
- = AltDataCon !Text
- | AltLit Lit
- | AltDefault
- type STopBinding = TopBinding' SBinder BinderId
- type TopBinding = TopBinding' Binder Binder
- data TopBinding' bndr var
- = NonRecTopBinding bndr CoreStats (Expr' bndr var)
- | RecTopBinding [(bndr, CoreStats, Expr' bndr var)]
- topBindings :: TopBinding' bndr var -> [(bndr, CoreStats, Expr' bndr var)]
- data CoreStats = CoreStats {
- csTerms :: !Int
- csTypes :: !Int
- csCoercions :: !Int
- csValBinds :: !Int
- csJoinBinds :: !Int
Documentation
Instances
Eq Unique Source # | |
Ord Unique Source # | |
Show Unique Source # | This is dependent upon GHC |
Generic Unique Source # | |
Serialise Unique Source # | |
type Rep Unique Source # | |
Defined in GhcDump.Ast type Rep Unique = D1 (MetaData "Unique" "GhcDump.Ast" "ghc-dump-core-0.1.1.0-Ii5eCp5CM7N2eU9noEy0C2" False) (C1 (MetaCons "Unique" PrefixI False) (S1 (MetaSel (Nothing :: Maybe Symbol) NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 Char) :*: S1 (MetaSel (Nothing :: Maybe Symbol) NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 Int))) |
data ExternalName Source #
ExternalName | |
| |
ForeignCall |
Instances
binderUniqueName :: Binder -> Text Source #
data Binder' bndr var Source #
Binder | |
| |
TyBinder | |
|
Instances
IdInfo | |
|
Instances
data Unfolding bndr var Source #
NoUnfolding | |
BootUnfolding | |
OtherCon [AltCon] | |
DFunUnfolding | |
CoreUnfolding | |
|
Instances
OccManyOccs | |
OccDead | introduced in GHC 8.2 |
OccOneOcc | |
OccLoopBreaker | |
Instances
Eq OccInfo Source # | |
Ord OccInfo Source # | |
Show OccInfo Source # | |
Generic OccInfo Source # | |
Serialise OccInfo Source # | |
type Rep OccInfo Source # | |
Defined in GhcDump.Ast type Rep OccInfo = D1 (MetaData "OccInfo" "GhcDump.Ast" "ghc-dump-core-0.1.1.0-Ii5eCp5CM7N2eU9noEy0C2" False) ((C1 (MetaCons "OccManyOccs" PrefixI False) (U1 :: Type -> Type) :+: C1 (MetaCons "OccDead" PrefixI False) (U1 :: Type -> Type)) :+: (C1 (MetaCons "OccOneOcc" PrefixI False) (U1 :: Type -> Type) :+: C1 (MetaCons "OccLoopBreaker" PrefixI True) (S1 (MetaSel (Just "occStrongLoopBreaker") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 Bool)))) |
VanillaId | |
RecSelId | |
DataConWorkId | |
DataConWrapId | |
ClassOpId | |
PrimOpId | |
TickBoxOpId | FCallId (these are treated as ExternalNames since they have no binding site) |
DFunId | |
CoVarId | |
JoinId | introduced in GHC 8.0 |
|
Instances
Instances
Instances
Eq TyCon Source # | |
Ord TyCon Source # | |
Show TyCon Source # | |
Generic TyCon Source # | |
Serialise TyCon Source # | |
type Rep TyCon Source # | |
Defined in GhcDump.Ast type Rep TyCon = D1 (MetaData "TyCon" "GhcDump.Ast" "ghc-dump-core-0.1.1.0-Ii5eCp5CM7N2eU9noEy0C2" False) (C1 (MetaCons "TyCon" PrefixI False) (S1 (MetaSel (Nothing :: Maybe Symbol) NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 Text) :*: S1 (MetaSel (Nothing :: Maybe Symbol) NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 Unique))) |
VarTy var | |
FunTy (Type' bndr var) (Type' bndr var) | |
TyConApp TyCon [Type' bndr var] | |
AppTy (Type' bndr var) (Type' bndr var) | |
ForAllTy bndr (Type' bndr var) | |
LitTy | |
CoercionTy |
Instances
newtype ModuleName Source #
Instances
Eq ModuleName Source # | |
Defined in GhcDump.Ast (==) :: ModuleName -> ModuleName -> Bool # (/=) :: ModuleName -> ModuleName -> Bool # | |
Ord ModuleName Source # | |
Defined in GhcDump.Ast compare :: ModuleName -> ModuleName -> Ordering # (<) :: ModuleName -> ModuleName -> Bool # (<=) :: ModuleName -> ModuleName -> Bool # (>) :: ModuleName -> ModuleName -> Bool # (>=) :: ModuleName -> ModuleName -> Bool # max :: ModuleName -> ModuleName -> ModuleName # min :: ModuleName -> ModuleName -> ModuleName # | |
Show ModuleName Source # | |
Defined in GhcDump.Ast showsPrec :: Int -> ModuleName -> ShowS # show :: ModuleName -> String # showList :: [ModuleName] -> ShowS # | |
Serialise ModuleName Source # | |
Defined in GhcDump.Ast encode :: ModuleName -> Encoding # decode :: Decoder s ModuleName # encodeList :: [ModuleName] -> Encoding # decodeList :: Decoder s [ModuleName] # |
data Module' bndr var Source #
Module | |
|
Instances
(Show bndr, Show var) => Show (Module' bndr var) Source # | |
Generic (Module' bndr var) Source # | |
(Serialise bndr, Serialise var) => Serialise (Module' bndr var) Source # | |
type Rep (Module' bndr var) Source # | |
Defined in GhcDump.Ast type Rep (Module' bndr var) = D1 (MetaData "Module'" "GhcDump.Ast" "ghc-dump-core-0.1.1.0-Ii5eCp5CM7N2eU9noEy0C2" False) (C1 (MetaCons "Module" PrefixI True) (S1 (MetaSel (Just "moduleName") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 ModuleName) :*: (S1 (MetaSel (Just "modulePhase") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 Text) :*: S1 (MetaSel (Just "moduleTopBindings") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 [TopBinding' bndr var])))) |
The binder story:
Things which might contain bound variables (e.g. expressions and types) have
a type variable which is instantiated at BinderId
in the serialised form or
Binder
after post-processing.
Note that bindings sites themselves are always Binder
s.
EVar var | |
EVarGlobal ExternalName | |
ELit Lit | |
EApp (Expr' bndr var) (Expr' bndr var) | |
ETyLam bndr (Expr' bndr var) | |
ELam bndr (Expr' bndr var) | |
ELet [(bndr, Expr' bndr var)] (Expr' bndr var) | |
ECase (Expr' bndr var) bndr [Alt' bndr var] | |
EType (Type' bndr var) | |
ECoercion |
Instances
Instances
(Eq bndr, Eq var) => Eq (Alt' bndr var) Source # | |
(Ord bndr, Ord var) => Ord (Alt' bndr var) Source # | |
Defined in GhcDump.Ast compare :: Alt' bndr var -> Alt' bndr var -> Ordering # (<) :: Alt' bndr var -> Alt' bndr var -> Bool # (<=) :: Alt' bndr var -> Alt' bndr var -> Bool # (>) :: Alt' bndr var -> Alt' bndr var -> Bool # (>=) :: Alt' bndr var -> Alt' bndr var -> Bool # | |
(Show bndr, Show var) => Show (Alt' bndr var) Source # | |
Generic (Alt' bndr var) Source # | |
(Serialise bndr, Serialise var) => Serialise (Alt' bndr var) Source # | |
type Rep (Alt' bndr var) Source # | |
Defined in GhcDump.Ast type Rep (Alt' bndr var) = D1 (MetaData "Alt'" "GhcDump.Ast" "ghc-dump-core-0.1.1.0-Ii5eCp5CM7N2eU9noEy0C2" False) (C1 (MetaCons "Alt" PrefixI True) (S1 (MetaSel (Just "altCon") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 AltCon) :*: (S1 (MetaSel (Just "altBinders") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 [bndr]) :*: S1 (MetaSel (Just "altRHS") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 (Expr' bndr var))))) |
Instances
Eq AltCon Source # | |
Ord AltCon Source # | |
Show AltCon Source # | |
Generic AltCon Source # | |
Serialise AltCon Source # | |
type Rep AltCon Source # | |
Defined in GhcDump.Ast type Rep AltCon = D1 (MetaData "AltCon" "GhcDump.Ast" "ghc-dump-core-0.1.1.0-Ii5eCp5CM7N2eU9noEy0C2" False) (C1 (MetaCons "AltDataCon" PrefixI False) (S1 (MetaSel (Nothing :: Maybe Symbol) NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 Text)) :+: (C1 (MetaCons "AltLit" PrefixI False) (S1 (MetaSel (Nothing :: Maybe Symbol) NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 Lit)) :+: C1 (MetaCons "AltDefault" PrefixI False) (U1 :: Type -> Type))) |
type STopBinding = TopBinding' SBinder BinderId Source #
type TopBinding = TopBinding' Binder Binder Source #
data TopBinding' bndr var Source #
NonRecTopBinding bndr CoreStats (Expr' bndr var) | |
RecTopBinding [(bndr, CoreStats, Expr' bndr var)] |
Instances
topBindings :: TopBinding' bndr var -> [(bndr, CoreStats, Expr' bndr var)] Source #
CoreStats | |
|
Instances
Show CoreStats Source # | |
Generic CoreStats Source # | |
Semigroup CoreStats Source # | |
Monoid CoreStats Source # | |
Serialise CoreStats Source # | |
type Rep CoreStats Source # | |
Defined in GhcDump.Ast type Rep CoreStats = D1 (MetaData "CoreStats" "GhcDump.Ast" "ghc-dump-core-0.1.1.0-Ii5eCp5CM7N2eU9noEy0C2" False) (C1 (MetaCons "CoreStats" PrefixI True) ((S1 (MetaSel (Just "csTerms") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 Int) :*: S1 (MetaSel (Just "csTypes") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 Int)) :*: (S1 (MetaSel (Just "csCoercions") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 Int) :*: (S1 (MetaSel (Just "csValBinds") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 Int) :*: S1 (MetaSel (Just "csJoinBinds") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 Int))))) |