ghc-8.2.1: The GHC API

Safe HaskellNone
LanguageHaskell2010

HsTypes

Synopsis

Documentation

data HsType name Source #

Haskell Type

Constructors

HsForAllTy

Fields

HsQualTy 

Fields

HsTyVar Promoted (Located name)
HsAppsTy [LHsAppType name]
HsAppTy (LHsType name) (LHsType name)
HsFunTy (LHsType name) (LHsType name)
HsListTy (LHsType name)
HsPArrTy (LHsType name)
HsTupleTy HsTupleSort [LHsType name]
HsSumTy [LHsType name]
HsOpTy (LHsType name) (Located name) (LHsType name)
HsParTy (LHsType name)
HsIParamTy (Located HsIPName) (LHsType name)
(?x :: ty)
HsEqTy (LHsType name) (LHsType name)
ty1 ~ ty2
HsKindSig (LHsType name) (LHsKind name)
(ty :: kind)
HsSpliceTy (HsSplice name) (PostTc name Kind)
HsDocTy (LHsType name) LHsDocString
HsBangTy HsSrcBang (LHsType name)
HsRecTy [LConDeclField name]
HsCoreTy Type
HsExplicitListTy Promoted (PostTc name Kind) [LHsType name]
HsExplicitTupleTy [PostTc name Kind] [LHsType name]
HsTyLit HsTyLit
HsWildCardTy (HsWildCardInfo name)

Instances

DataId name => Data (HsType name) Source # 

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> HsType name -> c (HsType name) #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c (HsType name) #

toConstr :: HsType name -> Constr #

dataTypeOf :: HsType name -> DataType #

dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c (HsType name)) #

dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c (HsType name)) #

gmapT :: (forall b. Data b => b -> b) -> HsType name -> HsType name #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> HsType name -> r #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> HsType name -> r #

gmapQ :: (forall d. Data d => d -> u) -> HsType name -> [u] #

gmapQi :: Int -> (forall d. Data d => d -> u) -> HsType name -> u #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> HsType name -> m (HsType name) #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> HsType name -> m (HsType name) #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> HsType name -> m (HsType name) #

OutputableBndrId name => Outputable (HsType name) Source # 

Methods

ppr :: HsType name -> SDoc Source #

pprPrec :: Rational -> HsType name -> SDoc Source #

type LHsType name Source #

Arguments

 = Located (HsType name)

May have AnnKeywordId : AnnComma when in a list

Located Haskell Type

type HsKind name = HsType name Source #

Haskell Kind

type LHsKind name Source #

Arguments

 = Located (HsKind name)

AnnKeywordId : AnnDcolon

Located Haskell Kind

data HsTyVarBndr name Source #

Haskell Type Variable Binder

Instances

DataId name => Data (HsTyVarBndr name) Source # 

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> HsTyVarBndr name -> c (HsTyVarBndr name) #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c (HsTyVarBndr name) #

toConstr :: HsTyVarBndr name -> Constr #

dataTypeOf :: HsTyVarBndr name -> DataType #

dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c (HsTyVarBndr name)) #

dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c (HsTyVarBndr name)) #

gmapT :: (forall b. Data b => b -> b) -> HsTyVarBndr name -> HsTyVarBndr name #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> HsTyVarBndr name -> r #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> HsTyVarBndr name -> r #

gmapQ :: (forall d. Data d => d -> u) -> HsTyVarBndr name -> [u] #

gmapQi :: Int -> (forall d. Data d => d -> u) -> HsTyVarBndr name -> u #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> HsTyVarBndr name -> m (HsTyVarBndr name) #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> HsTyVarBndr name -> m (HsTyVarBndr name) #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> HsTyVarBndr name -> m (HsTyVarBndr name) #

OutputableBndrId name => Outputable (HsTyVarBndr name) Source # 

type LHsTyVarBndr name = Located (HsTyVarBndr name) Source #

Located Haskell Type Variable Binder

data LHsQTyVars name Source #

Located Haskell Quantified Type Variables

Constructors

HsQTvs 

Instances

DataId name => Data (LHsQTyVars name) Source # 

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> LHsQTyVars name -> c (LHsQTyVars name) #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c (LHsQTyVars name) #

toConstr :: LHsQTyVars name -> Constr #

dataTypeOf :: LHsQTyVars name -> DataType #

dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c (LHsQTyVars name)) #

dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c (LHsQTyVars name)) #

gmapT :: (forall b. Data b => b -> b) -> LHsQTyVars name -> LHsQTyVars name #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> LHsQTyVars name -> r #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> LHsQTyVars name -> r #

gmapQ :: (forall d. Data d => d -> u) -> LHsQTyVars name -> [u] #

gmapQi :: Int -> (forall d. Data d => d -> u) -> LHsQTyVars name -> u #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> LHsQTyVars name -> m (LHsQTyVars name) #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> LHsQTyVars name -> m (LHsQTyVars name) #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> LHsQTyVars name -> m (LHsQTyVars name) #

OutputableBndrId name => Outputable (LHsQTyVars name) Source # 

Methods

ppr :: LHsQTyVars name -> SDoc Source #

pprPrec :: Rational -> LHsQTyVars name -> SDoc Source #

data HsImplicitBndrs name thing Source #

Haskell Implicit Binders

Constructors

HsIB 

Fields

Instances

(Data name, Data thing, Data (PostRn name [Name]), Data (PostRn name Bool)) => Data (HsImplicitBndrs name thing) Source # 

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> HsImplicitBndrs name thing -> c (HsImplicitBndrs name thing) #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c (HsImplicitBndrs name thing) #

toConstr :: HsImplicitBndrs name thing -> Constr #

dataTypeOf :: HsImplicitBndrs name thing -> DataType #

dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c (HsImplicitBndrs name thing)) #

dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c (HsImplicitBndrs name thing)) #

gmapT :: (forall b. Data b => b -> b) -> HsImplicitBndrs name thing -> HsImplicitBndrs name thing #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> HsImplicitBndrs name thing -> r #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> HsImplicitBndrs name thing -> r #

gmapQ :: (forall d. Data d => d -> u) -> HsImplicitBndrs name thing -> [u] #

gmapQi :: Int -> (forall d. Data d => d -> u) -> HsImplicitBndrs name thing -> u #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> HsImplicitBndrs name thing -> m (HsImplicitBndrs name thing) #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> HsImplicitBndrs name thing -> m (HsImplicitBndrs name thing) #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> HsImplicitBndrs name thing -> m (HsImplicitBndrs name thing) #

Outputable thing => Outputable (HsImplicitBndrs name thing) Source # 

Methods

ppr :: HsImplicitBndrs name thing -> SDoc Source #

pprPrec :: Rational -> HsImplicitBndrs name thing -> SDoc Source #

data HsWildCardBndrs name thing Source #

Haskell Wildcard Binders

Constructors

HsWC 

Fields

Instances

(Data name, Data thing, Data (PostRn name [Name])) => Data (HsWildCardBndrs name thing) Source # 

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> HsWildCardBndrs name thing -> c (HsWildCardBndrs name thing) #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c (HsWildCardBndrs name thing) #

toConstr :: HsWildCardBndrs name thing -> Constr #

dataTypeOf :: HsWildCardBndrs name thing -> DataType #

dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c (HsWildCardBndrs name thing)) #

dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c (HsWildCardBndrs name thing)) #

gmapT :: (forall b. Data b => b -> b) -> HsWildCardBndrs name thing -> HsWildCardBndrs name thing #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> HsWildCardBndrs name thing -> r #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> HsWildCardBndrs name thing -> r #

gmapQ :: (forall d. Data d => d -> u) -> HsWildCardBndrs name thing -> [u] #

gmapQi :: Int -> (forall d. Data d => d -> u) -> HsWildCardBndrs name thing -> u #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> HsWildCardBndrs name thing -> m (HsWildCardBndrs name thing) #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> HsWildCardBndrs name thing -> m (HsWildCardBndrs name thing) #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> HsWildCardBndrs name thing -> m (HsWildCardBndrs name thing) #

Outputable thing => Outputable (HsWildCardBndrs name thing) Source # 

Methods

ppr :: HsWildCardBndrs name thing -> SDoc Source #

pprPrec :: Rational -> HsWildCardBndrs name thing -> SDoc Source #

type LHsSigType name = HsImplicitBndrs name (LHsType name) Source #

Located Haskell Signature Type

type LHsSigWcType name = HsWildCardBndrs name (LHsSigType name) Source #

Located Haskell Signature Wildcard Type

type LHsWcType name = HsWildCardBndrs name (LHsType name) Source #

Located Haskell Wildcard Type

data HsTupleSort Source #

Haskell Tuple Sort

Instances

Data HsTupleSort Source # 

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> HsTupleSort -> c HsTupleSort #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c HsTupleSort #

toConstr :: HsTupleSort -> Constr #

dataTypeOf :: HsTupleSort -> DataType #

dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c HsTupleSort) #

dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c HsTupleSort) #

gmapT :: (forall b. Data b => b -> b) -> HsTupleSort -> HsTupleSort #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> HsTupleSort -> r #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> HsTupleSort -> r #

gmapQ :: (forall d. Data d => d -> u) -> HsTupleSort -> [u] #

gmapQi :: Int -> (forall d. Data d => d -> u) -> HsTupleSort -> u #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> HsTupleSort -> m HsTupleSort #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> HsTupleSort -> m HsTupleSort #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> HsTupleSort -> m HsTupleSort #

data Promoted Source #

Promoted data types.

Constructors

Promoted 
NotPromoted 

Instances

Eq Promoted Source # 
Data Promoted Source # 

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> Promoted -> c Promoted #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c Promoted #

toConstr :: Promoted -> Constr #

dataTypeOf :: Promoted -> DataType #

dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c Promoted) #

dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c Promoted) #

gmapT :: (forall b. Data b => b -> b) -> Promoted -> Promoted #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> Promoted -> r #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> Promoted -> r #

gmapQ :: (forall d. Data d => d -> u) -> Promoted -> [u] #

gmapQi :: Int -> (forall d. Data d => d -> u) -> Promoted -> u #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> Promoted -> m Promoted #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> Promoted -> m Promoted #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> Promoted -> m Promoted #

Show Promoted Source # 

type HsContext name = [LHsType name] Source #

Haskell Context

type LHsContext name Source #

Arguments

 = Located (HsContext name)

AnnKeywordId : AnnUnit

Located Haskell Context

data HsTyLit Source #

Haskell Type Literal

Instances

Data HsTyLit Source # 

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> HsTyLit -> c HsTyLit #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c HsTyLit #

toConstr :: HsTyLit -> Constr #

dataTypeOf :: HsTyLit -> DataType #

dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c HsTyLit) #

dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c HsTyLit) #

gmapT :: (forall b. Data b => b -> b) -> HsTyLit -> HsTyLit #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> HsTyLit -> r #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> HsTyLit -> r #

gmapQ :: (forall d. Data d => d -> u) -> HsTyLit -> [u] #

gmapQi :: Int -> (forall d. Data d => d -> u) -> HsTyLit -> u #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> HsTyLit -> m HsTyLit #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> HsTyLit -> m HsTyLit #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> HsTyLit -> m HsTyLit #

Outputable HsTyLit Source # 

newtype HsIPName Source #

These names are used early on to store the names of implicit parameters. They completely disappear after type-checking.

Constructors

HsIPName FastString 

Instances

Eq HsIPName Source # 
Data HsIPName Source # 

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> HsIPName -> c HsIPName #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c HsIPName #

toConstr :: HsIPName -> Constr #

dataTypeOf :: HsIPName -> DataType #

dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c HsIPName) #

dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c HsIPName) #

gmapT :: (forall b. Data b => b -> b) -> HsIPName -> HsIPName #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> HsIPName -> r #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> HsIPName -> r #

gmapQ :: (forall d. Data d => d -> u) -> HsIPName -> [u] #

gmapQi :: Int -> (forall d. Data d => d -> u) -> HsIPName -> u #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> HsIPName -> m HsIPName #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> HsIPName -> m HsIPName #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> HsIPName -> m HsIPName #

OutputableBndr HsIPName Source # 
Outputable HsIPName Source # 

data HsAppType name Source #

Haskell Application Type

Constructors

HsAppInfix (Located name) 
HsAppPrefix (LHsType name) 

Instances

DataId name => Data (HsAppType name) Source # 

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> HsAppType name -> c (HsAppType name) #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c (HsAppType name) #

toConstr :: HsAppType name -> Constr #

dataTypeOf :: HsAppType name -> DataType #

dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c (HsAppType name)) #

dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c (HsAppType name)) #

gmapT :: (forall b. Data b => b -> b) -> HsAppType name -> HsAppType name #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> HsAppType name -> r #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> HsAppType name -> r #

gmapQ :: (forall d. Data d => d -> u) -> HsAppType name -> [u] #

gmapQi :: Int -> (forall d. Data d => d -> u) -> HsAppType name -> u #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> HsAppType name -> m (HsAppType name) #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> HsAppType name -> m (HsAppType name) #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> HsAppType name -> m (HsAppType name) #

OutputableBndrId name => Outputable (HsAppType name) Source # 

Methods

ppr :: HsAppType name -> SDoc Source #

pprPrec :: Rational -> HsAppType name -> SDoc Source #

type LHsAppType name Source #

Located Haskell Application Type

type LBangType name = Located (BangType name) Source #

Located Bang Type

type BangType name = HsType name Source #

Bang Type

data HsSrcBang Source #

Haskell Source Bang

Bangs on data constructor arguments as the user wrote them in the source code.

(HsSrcBang _ SrcUnpack SrcLazy) and (HsSrcBang _ SrcUnpack NoSrcStrict) (without StrictData) makes no sense, we emit a warning (in checkValidDataCon) and treat it like (HsSrcBang _ NoSrcUnpack SrcLazy)

Instances

Data HsSrcBang Source # 

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> HsSrcBang -> c HsSrcBang #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c HsSrcBang #

toConstr :: HsSrcBang -> Constr #

dataTypeOf :: HsSrcBang -> DataType #

dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c HsSrcBang) #

dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c HsSrcBang) #

gmapT :: (forall b. Data b => b -> b) -> HsSrcBang -> HsSrcBang #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> HsSrcBang -> r #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> HsSrcBang -> r #

gmapQ :: (forall d. Data d => d -> u) -> HsSrcBang -> [u] #

gmapQi :: Int -> (forall d. Data d => d -> u) -> HsSrcBang -> u #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> HsSrcBang -> m HsSrcBang #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> HsSrcBang -> m HsSrcBang #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> HsSrcBang -> m HsSrcBang #

Outputable HsSrcBang Source # 

data HsImplBang Source #

Haskell Implementation Bang

Bangs of data constructor arguments as generated by the compiler after consulting HsSrcBang, flags, etc.

Constructors

HsLazy

Lazy field

HsStrict

Strict but not unpacked field

HsUnpack (Maybe Coercion)

Strict and unpacked field co :: arg-ty ~ product-ty HsBang

Instances

Data HsImplBang Source # 

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> HsImplBang -> c HsImplBang #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c HsImplBang #

toConstr :: HsImplBang -> Constr #

dataTypeOf :: HsImplBang -> DataType #

dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c HsImplBang) #

dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c HsImplBang) #

gmapT :: (forall b. Data b => b -> b) -> HsImplBang -> HsImplBang #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> HsImplBang -> r #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> HsImplBang -> r #

gmapQ :: (forall d. Data d => d -> u) -> HsImplBang -> [u] #

gmapQi :: Int -> (forall d. Data d => d -> u) -> HsImplBang -> u #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> HsImplBang -> m HsImplBang #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> HsImplBang -> m HsImplBang #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> HsImplBang -> m HsImplBang #

Outputable HsImplBang Source # 

data SrcStrictness Source #

Source Strictness

What strictness annotation the user wrote

Constructors

SrcLazy

Lazy, ie '~'

SrcStrict

Strict, ie !

NoSrcStrict

no strictness annotation

Instances

Eq SrcStrictness Source # 
Data SrcStrictness Source # 

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> SrcStrictness -> c SrcStrictness #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c SrcStrictness #

toConstr :: SrcStrictness -> Constr #

dataTypeOf :: SrcStrictness -> DataType #

dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c SrcStrictness) #

dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c SrcStrictness) #

gmapT :: (forall b. Data b => b -> b) -> SrcStrictness -> SrcStrictness #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> SrcStrictness -> r #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> SrcStrictness -> r #

gmapQ :: (forall d. Data d => d -> u) -> SrcStrictness -> [u] #

gmapQi :: Int -> (forall d. Data d => d -> u) -> SrcStrictness -> u #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> SrcStrictness -> m SrcStrictness #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> SrcStrictness -> m SrcStrictness #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> SrcStrictness -> m SrcStrictness #

Outputable SrcStrictness Source # 
Binary SrcStrictness Source # 

data SrcUnpackedness Source #

Source Unpackedness

What unpackedness the user requested

Constructors

SrcUnpack

{--} specified

SrcNoUnpack

{--} specified

NoSrcUnpack

no unpack pragma

Instances

Eq SrcUnpackedness Source # 
Data SrcUnpackedness Source # 

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> SrcUnpackedness -> c SrcUnpackedness #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c SrcUnpackedness #

toConstr :: SrcUnpackedness -> Constr #

dataTypeOf :: SrcUnpackedness -> DataType #

dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c SrcUnpackedness) #

dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c SrcUnpackedness) #

gmapT :: (forall b. Data b => b -> b) -> SrcUnpackedness -> SrcUnpackedness #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> SrcUnpackedness -> r #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> SrcUnpackedness -> r #

gmapQ :: (forall d. Data d => d -> u) -> SrcUnpackedness -> [u] #

gmapQi :: Int -> (forall d. Data d => d -> u) -> SrcUnpackedness -> u #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> SrcUnpackedness -> m SrcUnpackedness #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> SrcUnpackedness -> m SrcUnpackedness #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> SrcUnpackedness -> m SrcUnpackedness #

Outputable SrcUnpackedness Source # 
Binary SrcUnpackedness Source # 

data ConDeclField name Source #

Constructor Declaration Field

Constructors

ConDeclField

Fields

Instances

DataId name => Data (ConDeclField name) Source # 

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> ConDeclField name -> c (ConDeclField name) #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c (ConDeclField name) #

toConstr :: ConDeclField name -> Constr #

dataTypeOf :: ConDeclField name -> DataType #

dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c (ConDeclField name)) #

dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c (ConDeclField name)) #

gmapT :: (forall b. Data b => b -> b) -> ConDeclField name -> ConDeclField name #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> ConDeclField name -> r #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> ConDeclField name -> r #

gmapQ :: (forall d. Data d => d -> u) -> ConDeclField name -> [u] #

gmapQi :: Int -> (forall d. Data d => d -> u) -> ConDeclField name -> u #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> ConDeclField name -> m (ConDeclField name) #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> ConDeclField name -> m (ConDeclField name) #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> ConDeclField name -> m (ConDeclField name) #

OutputableBndrId name => Outputable (ConDeclField name) Source # 

type LConDeclField name Source #

Arguments

 = Located (ConDeclField name)

May have AnnKeywordId : AnnComma when in a list

Located Constructor Declaration Field

updateGadtResult Source #

Arguments

:: Monad m 
=> (SDoc -> m ()) 
-> SDoc 
-> HsConDetails (LHsType Name) (Located [LConDeclField Name])

Original details

-> LHsType Name

Original result type

-> m (HsConDetails (LHsType Name) (Located [LConDeclField Name]), LHsType Name) 

data HsConDetails arg rec Source #

Haskell Constructor Details

Constructors

PrefixCon [arg] 
RecCon rec 
InfixCon arg arg 

Instances

(Data rec, Data arg) => Data (HsConDetails arg rec) Source # 

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> HsConDetails arg rec -> c (HsConDetails arg rec) #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c (HsConDetails arg rec) #

toConstr :: HsConDetails arg rec -> Constr #

dataTypeOf :: HsConDetails arg rec -> DataType #

dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c (HsConDetails arg rec)) #

dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c (HsConDetails arg rec)) #

gmapT :: (forall b. Data b => b -> b) -> HsConDetails arg rec -> HsConDetails arg rec #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> HsConDetails arg rec -> r #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> HsConDetails arg rec -> r #

gmapQ :: (forall d. Data d => d -> u) -> HsConDetails arg rec -> [u] #

gmapQi :: Int -> (forall d. Data d => d -> u) -> HsConDetails arg rec -> u #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> HsConDetails arg rec -> m (HsConDetails arg rec) #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> HsConDetails arg rec -> m (HsConDetails arg rec) #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> HsConDetails arg rec -> m (HsConDetails arg rec) #

(Outputable arg, Outputable rec) => Outputable (HsConDetails arg rec) Source # 

Methods

ppr :: HsConDetails arg rec -> SDoc Source #

pprPrec :: Rational -> HsConDetails arg rec -> SDoc Source #

data FieldOcc name Source #

Field Occurrence

Represents an *occurrence* of an unambiguous field. We store both the RdrName the user originally wrote, and after the renamer, the selector function.

Constructors

FieldOcc 

Fields

Instances

Eq (PostRn name name) => Eq (FieldOcc name) Source # 

Methods

(==) :: FieldOcc name -> FieldOcc name -> Bool #

(/=) :: FieldOcc name -> FieldOcc name -> Bool #

(Data name, Data (PostRn name name)) => Data (FieldOcc name) Source # 

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> FieldOcc name -> c (FieldOcc name) #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c (FieldOcc name) #

toConstr :: FieldOcc name -> Constr #

dataTypeOf :: FieldOcc name -> DataType #

dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c (FieldOcc name)) #

dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c (FieldOcc name)) #

gmapT :: (forall b. Data b => b -> b) -> FieldOcc name -> FieldOcc name #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> FieldOcc name -> r #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> FieldOcc name -> r #

gmapQ :: (forall d. Data d => d -> u) -> FieldOcc name -> [u] #

gmapQi :: Int -> (forall d. Data d => d -> u) -> FieldOcc name -> u #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> FieldOcc name -> m (FieldOcc name) #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> FieldOcc name -> m (FieldOcc name) #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> FieldOcc name -> m (FieldOcc name) #

Ord (PostRn name name) => Ord (FieldOcc name) Source # 

Methods

compare :: FieldOcc name -> FieldOcc name -> Ordering #

(<) :: FieldOcc name -> FieldOcc name -> Bool #

(<=) :: FieldOcc name -> FieldOcc name -> Bool #

(>) :: FieldOcc name -> FieldOcc name -> Bool #

(>=) :: FieldOcc name -> FieldOcc name -> Bool #

max :: FieldOcc name -> FieldOcc name -> FieldOcc name #

min :: FieldOcc name -> FieldOcc name -> FieldOcc name #

Outputable (FieldOcc name) Source # 

Methods

ppr :: FieldOcc name -> SDoc Source #

pprPrec :: Rational -> FieldOcc name -> SDoc Source #

type LFieldOcc name = Located (FieldOcc name) Source #

Located Field Occurrence

data AmbiguousFieldOcc name Source #

Ambiguous Field Occurrence

Represents an *occurrence* of a field that is potentially ambiguous after the renamer, with the ambiguity resolved by the typechecker. We always store the RdrName that the user originally wrote, and store the selector function after the renamer (for unambiguous occurrences) or the typechecker (for ambiguous occurrences).

See Note [HsRecField and HsRecUpdField] in HsPat and Note [Disambiguating record fields] in TcExpr. See Note [Located RdrNames] in HsExpr

Constructors

Unambiguous (Located RdrName) (PostRn name name) 
Ambiguous (Located RdrName) (PostTc name name) 

Instances

(Data name, Data (PostRn name name), Data (PostTc name name)) => Data (AmbiguousFieldOcc name) Source # 

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> AmbiguousFieldOcc name -> c (AmbiguousFieldOcc name) #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c (AmbiguousFieldOcc name) #

toConstr :: AmbiguousFieldOcc name -> Constr #

dataTypeOf :: AmbiguousFieldOcc name -> DataType #

dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c (AmbiguousFieldOcc name)) #

dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c (AmbiguousFieldOcc name)) #

gmapT :: (forall b. Data b => b -> b) -> AmbiguousFieldOcc name -> AmbiguousFieldOcc name #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> AmbiguousFieldOcc name -> r #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> AmbiguousFieldOcc name -> r #

gmapQ :: (forall d. Data d => d -> u) -> AmbiguousFieldOcc name -> [u] #

gmapQi :: Int -> (forall d. Data d => d -> u) -> AmbiguousFieldOcc name -> u #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> AmbiguousFieldOcc name -> m (AmbiguousFieldOcc name) #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> AmbiguousFieldOcc name -> m (AmbiguousFieldOcc name) #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> AmbiguousFieldOcc name -> m (AmbiguousFieldOcc name) #

OutputableBndr (AmbiguousFieldOcc name) Source # 
Outputable (AmbiguousFieldOcc name) Source # 

newtype HsWildCardInfo name Source #

Constructors

AnonWildCard (PostRn name (Located Name)) 

Instances

DataId name => Data (HsWildCardInfo name) Source # 

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> HsWildCardInfo name -> c (HsWildCardInfo name) #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c (HsWildCardInfo name) #

toConstr :: HsWildCardInfo name -> Constr #

dataTypeOf :: HsWildCardInfo name -> DataType #

dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c (HsWildCardInfo name)) #

dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c (HsWildCardInfo name)) #

gmapT :: (forall b. Data b => b -> b) -> HsWildCardInfo name -> HsWildCardInfo name #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> HsWildCardInfo name -> r #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> HsWildCardInfo name -> r #

gmapQ :: (forall d. Data d => d -> u) -> HsWildCardInfo name -> [u] #

gmapQi :: Int -> (forall d. Data d => d -> u) -> HsWildCardInfo name -> u #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> HsWildCardInfo name -> m (HsWildCardInfo name) #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> HsWildCardInfo name -> m (HsWildCardInfo name) #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> HsWildCardInfo name -> m (HsWildCardInfo name) #

Outputable (HsWildCardInfo name) Source # 

hsImplicitBody :: HsImplicitBndrs name thing -> thing Source #

isHsKindedTyVar :: HsTyVarBndr name -> Bool Source #

Does this HsTyVarBndr come with an explicit kind annotation?

hsTvbAllKinded :: LHsQTyVars name -> Bool Source #

Do all type variables in this LHsQTyVars come with kind annotations?

splitLHsPatSynTy :: LHsType name -> ([LHsTyVarBndr name], LHsContext name, [LHsTyVarBndr name], LHsContext name, LHsType name) Source #

splitHsAppsTy :: [LHsAppType name] -> ([[LHsType name]], [Located name]) Source #

Splits a [HsAppType name] (the payload of an HsAppsTy) into regions of prefix types (normal types) and infix operators. If splitHsAppsTy tys = (non_syms, syms), then tys starts with the first element of non_syms followed by the first element of syms followed by the next element of non_syms, etc. It is guaranteed that the non_syms list has one more element than the syms list.

getAppsTyHead_maybe :: [LHsAppType name] -> Maybe (LHsType name, [LHsType name], LexicalFixity) Source #

Retrieves the head of an HsAppsTy, if this can be done unambiguously, without consulting fixities.

mkHsOpTy :: LHsType name -> Located name -> LHsType name -> HsType name Source #

mkHsAppTy :: LHsType name -> LHsType name -> LHsType name Source #

mkHsAppTys :: LHsType name -> [LHsType name] -> LHsType name Source #

hsLTyVarBndrToType :: LHsTyVarBndr name -> LHsType name Source #

Convert a LHsTyVarBndr to an equivalent LHsType.

hsLTyVarBndrsToTypes :: LHsQTyVars name -> [LHsType name] Source #

Convert a LHsTyVarBndrs to a list of types. Works on *type* variable only, no kind vars.

pprHsForAllExtra :: OutputableBndrId name => Maybe SrcSpan -> [LHsTyVarBndr name] -> LHsContext name -> SDoc Source #

Version of pprHsForAll that can also print an extra-constraints wildcard, e.g. _ => a -> Bool or (Show a, _) => a -> String. This underscore will be printed when the 'Maybe SrcSpan' argument is a Just containing the location of the extra-constraints wildcard. A special function for this is needed, as the extra-constraints wildcard is removed from the actual context and type, and stored in a separate field, thus just printing the type will not print the extra-constraints wildcard.