HORIZON HASKELLDocslts/ghc-10.0.xfc4e5982026-10-11Search names, modules, packages, or :: a typeCtrl K

GHC 10.0.0.20260917 · lts/ghc-10.0.x · fc4e598 · 2026-10-11

Moduleghc-lib-parser-9.14.1.20251220GHC2021

Language.Haskell.Syntax.Extension

  • 4 types
  • 3 classes
  • 2 values
datadata NoExtField
#

A placeholder type for TTG extension points that are not currently used to represent any particular value.

This should not be confused with DataConCantHappen, which are found in unused extension constructors and therefore should never be inhabited. In contrast, NoExtField is used in extension points (e.g., as the field of some constructor), so it must have an inhabitant to construct AST passes that manipulate fields with that extension point as their type.

Instances4Eq, Data, Ord, Outputable
  • Eq NoExtFieldDefined in ghc-lib-parser-9.14.1.20251220 · Language.Haskell.Syntax.Extension
  • Data NoExtFieldDefined in ghc-lib-parser-9.14.1.20251220 · Language.Haskell.Syntax.Extension
  • Ord NoExtFieldDefined in ghc-lib-parser-9.14.1.20251220 · Language.Haskell.Syntax.Extension
  • Outputable NoExtFieldDefined in ghc-lib-parser-9.14.1.20251220 · GHC.Hs.Extension · orphan
familytype family XRec p a
#

GHC's L prefixed variants wrap their vanilla variant in this type family, to add SrcLoc info via Located. Other passes than GhcPass not interested in location information can define this as type instance XRec NoLocated a = a. See Note [XRec and SrcSpans in the AST]

Instances1XRec
  • type XRec (GhcPass p) a = XRecGhc aDefined in ghc-lib-parser-9.14.1.20251220 · GHC.Hs.Extension
familytype family Anno a
#
Instances99Anno, …
classclass UnXRec p where
#

We can strip off the XRec to access the underlying data. See Note [XRec and SrcSpans in the AST]

Methods

Instances1UnXRec
  • UnXRec (GhcPass p)Defined in ghc-lib-parser-9.14.1.20251220 · GHC.Hs.Extension
classclass MapXRec p where
#

We can map over the underlying type contained in an XRec while preserving the annotation as is.

Methods

Instances1MapXRec
  • MapXRec (GhcPass p)Defined in ghc-lib-parser-9.14.1.20251220 · GHC.Hs.Extension
classclass WrapXRec p a where
#

The trivial wrapper that carries no additional information See Note [XRec and SrcSpans in the AST]

Methods

Instances1WrapXRec
familytype family IdP p
#

Maps the "normal" id type for a given pass

Instances1IdP
  • type IdP (GhcPass p) = IdGhcP pDefined in ghc-lib-parser-9.14.1.20251220 · GHC.Hs.Extension
familytype family IdOccP p
#

Like IdP, except it keeps track of the user-written module qualification, if any.

See Note [IdOcc].

Instances1IdOccP
familytype family XFunBind x x'
#
Instances3XFunBind
  • type XFunBind (GhcPass pL) GhcPs = NoExtFieldDefined in ghc-lib-parser-9.14.1.20251220 · GHC.Hs.Binds · orphan
  • type XFunBind (GhcPass pL) GhcRn = NameSetDefined in ghc-lib-parser-9.14.1.20251220 · GHC.Hs.Binds · orphan

    After the renamer (but before the type-checker), the FunBind extension field contains the locally-bound free variables of this defn. See Note [Bind free vars]

  • type XFunBind (GhcPass pL) GhcTc = (HsWrapper, [CoreTickish])Defined in ghc-lib-parser-9.14.1.20251220 · GHC.Hs.Binds · orphan

    After the type-checker, the FunBind extension field contains the ticks to put on the rhs, if any, and a coercion from the type of the MatchGroup to the type of the Id. Example:

         f :: Int -> forall a. a -> a
         f x y = y
    

    Then the MatchGroup will have type (Int -> a' -> a') (with a free type variable a'). The coercion will take a CoreExpr of this type and convert it to a CoreExpr of type Int -> forall a'. a' -> a' Notice that the coercion captures the free a'.

familytype family XCIPBind x
#
Instances3XCIPBind
  • type XCIPBind GhcPs = EpToken "="Defined in ghc-lib-parser-9.14.1.20251220 · GHC.Hs.Binds · orphan
  • type XCIPBind GhcRn = NoExtFieldDefined in ghc-lib-parser-9.14.1.20251220 · GHC.Hs.Binds · orphan
  • type XCIPBind GhcTc = IdDefined in ghc-lib-parser-9.14.1.20251220 · GHC.Hs.Binds · orphan
familytype family XTypeSig x
#
Instances1XTypeSig
familytype family XXSig x
#
Instances3XXSig
  • type XXSig GhcPs = DataConCantHappenDefined in ghc-lib-parser-9.14.1.20251220 · GHC.Hs.Binds · orphan
  • type XXSig GhcRn = IdSigDefined in ghc-lib-parser-9.14.1.20251220 · GHC.Hs.Binds · orphan
  • type XXSig GhcTc = IdSigDefined in ghc-lib-parser-9.14.1.20251220 · GHC.Hs.Binds · orphan
familytype family XTyClD x
#
Instances1XTyClD
familytype family XInstD x
#
Instances1XInstD
familytype family XValD x
#
Instances1XValD
familytype family XSigD x
#
Instances1XSigD
familytype family XDefD x
#
Instances1XDefD
familytype family XForD x
#
Instances1XForD
familytype family XAnnD x
#
Instances1XAnnD
familytype family XRuleD x
#
Instances1XRuleD
familytype family XDocD x
#
Instances1XDocD
familytype family XNoSig x
#
Instances1XNoSig
familytype family XVar x
#
Instances1XVar
familytype family XLitE x
#
Instances1XLitE
familytype family XLam x
#
Instances1XLam
  • type XLam (GhcPass _1) = EpAnnLamDefined in ghc-lib-parser-9.14.1.20251220 · GHC.Hs.Expr · orphan
familytype family XApp x
#
Instances1XApp
familytype family XPar x
#
Instances3XPar
familytype family XIf x
#
Instances3XIf
  • type XIf GhcPs = AnnsIfDefined in ghc-lib-parser-9.14.1.20251220 · GHC.Hs.Expr · orphan
  • type XIf GhcRn = NoExtFieldDefined in ghc-lib-parser-9.14.1.20251220 · GHC.Hs.Expr · orphan
  • type XIf GhcTc = NoExtFieldDefined in ghc-lib-parser-9.14.1.20251220 · GHC.Hs.Expr · orphan
familytype family XLet x
#
Instances3XLet
familytype family XDo x
#
Instances3XDo
  • type XDo GhcPs = AnnList EpaLocationDefined in ghc-lib-parser-9.14.1.20251220 · GHC.Hs.Expr · orphan
  • type XDo GhcRn = NoExtFieldDefined in ghc-lib-parser-9.14.1.20251220 · GHC.Hs.Expr · orphan
  • type XDo GhcTc = TypeDefined in ghc-lib-parser-9.14.1.20251220 · GHC.Hs.Expr · orphan
familytype family XStatic x
#
Instances3XStatic
familytype family XTick x
#
familytype family XPragE x
#
Instances1XPragE
familytype family XHole x
#
Instances3XHole
  • type XHole GhcPs = HoleKindDefined in ghc-lib-parser-9.14.1.20251220 · GHC.Hs.Expr · orphan

    Expression Hole. See Note [Holes in expressions].

  • type XHole GhcRn = HoleKindDefined in ghc-lib-parser-9.14.1.20251220 · GHC.Hs.Expr · orphan
  • type XHole GhcTc = (HoleKind, HoleExprRef)Defined in ghc-lib-parser-9.14.1.20251220 · GHC.Hs.Expr · orphan
familytype family XFunRhs
#
Instances1XFunRhs
  • type XFunRhs = AnnFunRhsDefined in ghc-lib-parser-9.14.1.20251220 · GHC.Hs.Expr · orphan
familytype family XMG x b
#
Instances3XMG
  • type XMG GhcPs b = OriginDefined in ghc-lib-parser-9.14.1.20251220 · GHC.Hs.Expr · orphan
  • type XMG GhcRn b = OriginDefined in ghc-lib-parser-9.14.1.20251220 · GHC.Hs.Expr · orphan
  • type XMG GhcTc b = MatchGroupTcDefined in ghc-lib-parser-9.14.1.20251220 · GHC.Hs.Expr · orphan
familytype family XCmdArrForm x
#
Instances3XCmdArrForm
  • type XCmdArrForm GhcPs = AnnList ()Defined in ghc-lib-parser-9.14.1.20251220 · GHC.Hs.Expr · orphan
  • type XCmdArrForm GhcRn = Maybe FixityDefined in ghc-lib-parser-9.14.1.20251220 · GHC.Hs.Expr · orphan

    fixity (filled in by the renamer), for forms that were converted from OpApp's by the renamer

  • type XCmdArrForm GhcTc = Maybe FixityDefined in ghc-lib-parser-9.14.1.20251220 · GHC.Hs.Expr · orphan
familytype family XCmdIf x
#
Instances3XCmdIf
familytype family XHsInt x
#
Instances1XHsInt
familytype family XOrPat x
#
Instances3XOrPat
familytype family XNPat x
#
Instances3XNPat
  • type XNPat GhcPs = EpToken "-"Defined in ghc-lib-parser-9.14.1.20251220 · GHC.Hs.Pat · orphan
  • type XNPat GhcRn = EpToken "-"Defined in ghc-lib-parser-9.14.1.20251220 · GHC.Hs.Pat · orphan
  • type XNPat GhcTc = TypeDefined in ghc-lib-parser-9.14.1.20251220 · GHC.Hs.Pat · orphan
familytype family XHsQTvs x
#
Instances3XHsQTvs
  • type XHsQTvs GhcPs = NoExtFieldDefined in ghc-lib-parser-9.14.1.20251220 · GHC.Hs.Type · orphan
  • type XHsQTvs GhcRn = HsQTvsRnDefined in ghc-lib-parser-9.14.1.20251220 · GHC.Hs.Type · orphan
  • type XHsQTvs GhcTc = HsQTvsRnDefined in ghc-lib-parser-9.14.1.20251220 · GHC.Hs.Type · orphan
familytype family XHsSig x
#
Instances1XHsSig
familytype family XHsWC x b
#
Instances3XHsWC
  • type XHsWC GhcPs b = NoExtFieldDefined in ghc-lib-parser-9.14.1.20251220 · GHC.Hs.Type · orphan
  • type XHsWC GhcRn b = [Name]Defined in ghc-lib-parser-9.14.1.20251220 · GHC.Hs.Type · orphan
  • type XHsWC GhcTc b = [Name]Defined in ghc-lib-parser-9.14.1.20251220 · GHC.Hs.Type · orphan
familytype family XHsPS x
#
Instances3XHsPS
  • type XHsPS GhcPs = EpAnnCODefined in ghc-lib-parser-9.14.1.20251220 · GHC.Hs.Type · orphan
  • type XHsPS GhcRn = HsPSRnDefined in ghc-lib-parser-9.14.1.20251220 · GHC.Hs.Type · orphan
  • type XHsPS GhcTc = HsPSRnDefined in ghc-lib-parser-9.14.1.20251220 · GHC.Hs.Type · orphan
familytype family XTyVar x
#
Instances1XTyVar
  • type XTyVar (GhcPass _1) = EpToken "'"Defined in ghc-lib-parser-9.14.1.20251220 · GHC.Hs.Type · orphan
familytype family XAppTy x
#
Instances1XAppTy
familytype family XFunTy x
#
Instances1XFunTy
familytype family XListTy x
#
Instances1XListTy
familytype family XSumTy x
#
Instances1XSumTy
familytype family XOpTy x
#
Instances1XOpTy
familytype family XDocTy x
#
Instances1XDocTy
familytype family XTyLit x
#
Instances1XTyLit
familytype family XNumTy x
#
Instances1XNumTy
familytype family XStrTy x
#
Instances1XStrTy
familytype family XIEThingAll x
#
Instances3XIEThingAll
familytype family XIEDoc x
#
Instances1XIEDoc
familytype family XIEType p
#
Instances1XIEType
  • type XIEType (GhcPass _1) = EpToken "type"Defined in ghc-lib-parser-9.14.1.20251220 · GHC.Hs.ImpExp · orphan
familytype family XIEData p
#
Instances1XIEData
  • type XIEData (GhcPass _1) = EpToken "data"Defined in ghc-lib-parser-9.14.1.20251220 · GHC.Hs.ImpExp · orphan
familytype family NoGhcTc p
#

See Note [NoGhcTc] in GHC.Hs.Extension. It has to be in this module because it is used like an extension point (in the data definitions of types that should be parameter-agnostic.

Instances1NoGhcTc
  • type NoGhcTc (GhcPass pass) = GhcPass (NoGhcTcPass pass)Defined in ghc-lib-parser-9.14.1.20251220 · GHC.Hs.Extension

    Marks that a field uses the GhcRn variant even when the pass parameter is GhcTc. Useful for storing HsTypes in GHC.Hs.Exprs, say, because HsType GhcTc should never occur. See Note [NoGhcTc]