Safe Haskell | Safe |
---|---|
Language | Haskell2010 |
- Datatypes and Constructors
ModuleName
SpecialCon
QName
Name
IPName
QOp
Op
CName
Module
ModuleHead
ExportSpecList
ExportSpec
EWildcard
Namespace
ImportDecl
ImportSpecList
ImportSpec
Assoc
Decl
PatternSynDirection
TypeEqn
Annotation
BooleanFormula
Role
DataOrNew
InjectivityInfo
ResultSig
DeclHead
InstRule
InstHead
Deriving
DerivStrategy
Binds
IPBind
Match
QualConDecl
ConDecl
FieldDecl
GadtDecl
ClassDecl
InstDecl
BangType
Unpackedness
Rhs
GuardedRhs
Type
MaybePromotedName
Promoted
TyVarBind
Kind
FunDep
Context
Asst
Literal
Sign
Exp
XName
XAttr
Bracket
Splice
Safety
CallConv
ModulePragma
Overlap
Activation
Rule
RuleVar
WarningText
Pat
PXAttr
RPatOp
RPat
PatField
Stmt
QualStmt
FieldUpdate
Alt
- Functions
This module reexports a simplified view on Language.Haskell.Exts.Syntax. The idea is to expose datatypes like
data Name l = Ident l String | Symbol l String
using ghc's pattern synonyms:
type Name = H.Name () pattern Ident a = H.Ident () a pattern Symbol a = H.Symbol () a
This works nicely for all datatypes with two exception:
ImportDecl
has a record constructor. Record type synonyms are only supported ghc-8.0 and later, so for ghc-7.10 and earlier, the constructor is exported as a plain constructor, and the record fields as function.Literal
has constructors with an extraString
argument that is not used byPretty
. This module uses explicitly bidirectional pattern synonyms to support this type, but support for that is only available in ghc-7.10 and later.
IMPORTANT: if you require compatiblity with ghc 7.8, you should use the
functions charL
, stringL
etc. for constructing Literal
values!
- type ModuleName = ModuleName ()
- pattern ModuleName :: String -> ModuleName
- type SpecialCon = SpecialCon ()
- pattern UnitCon :: SpecialCon
- pattern ListCon :: SpecialCon
- pattern FunCon :: SpecialCon
- pattern TupleCon :: Boxed -> Int -> SpecialCon
- pattern Cons :: SpecialCon
- pattern UnboxedSingleCon :: SpecialCon
- pattern ExprHole :: SpecialCon
- type QName = QName ()
- pattern Qual :: ModuleName -> Name -> QName
- pattern UnQual :: Name -> QName
- pattern Special :: SpecialCon -> QName
- type Name = Name ()
- pattern Ident :: String -> Name
- pattern Symbol :: String -> Name
- type IPName = IPName ()
- pattern IPDup :: String -> IPName
- pattern IPLin :: String -> IPName
- type QOp = QOp ()
- pattern QVarOp :: QName -> QOp
- pattern QConOp :: QName -> QOp
- type Op = Op ()
- pattern VarOp :: Name -> Op
- pattern ConOp :: Name -> Op
- type CName = CName ()
- pattern VarName :: Name -> CName
- pattern ConName :: Name -> CName
- type Module = Module ()
- pattern Module :: Maybe ModuleHead -> [ModulePragma] -> [ImportDecl] -> [Decl] -> Module
- pattern XmlPage :: ModuleName -> [ModulePragma] -> XName -> [XAttr] -> Maybe Exp -> [Exp] -> Module
- pattern XmlHybrid :: Maybe ModuleHead -> [ModulePragma] -> [ImportDecl] -> [Decl] -> XName -> [XAttr] -> Maybe Exp -> [Exp] -> Module
- type ModuleHead = ModuleHead ()
- pattern ModuleHead :: ModuleName -> Maybe WarningText -> Maybe ExportSpecList -> ModuleHead
- type ExportSpecList = ExportSpecList ()
- pattern ExportSpecList :: [ExportSpec] -> ExportSpecList
- type ExportSpec = ExportSpec ()
- pattern EVar :: QName -> ExportSpec
- pattern EAbs :: Namespace -> QName -> ExportSpec
- pattern EThingWith :: EWildcard -> QName -> [CName] -> ExportSpec
- pattern EModuleContents :: ModuleName -> ExportSpec
- type EWildcard = EWildcard ()
- pattern NoWildcard :: EWildcard
- pattern EWildcard :: Int -> EWildcard
- type Namespace = Namespace ()
- pattern NoNamespace :: Namespace
- pattern TypeNamespace :: Namespace
- pattern PatternNamespace :: Namespace
- type ImportDecl = ImportDecl ()
- pattern ImportDecl :: ModuleName () -> Bool -> Bool -> Bool -> Maybe String -> Maybe (ModuleName ()) -> Maybe (ImportSpecList ()) -> ImportDecl
- type ImportSpecList = ImportSpecList ()
- pattern ImportSpecList :: Bool -> [ImportSpec] -> ImportSpecList
- type ImportSpec = ImportSpec ()
- pattern IVar :: Name -> ImportSpec
- pattern IAbs :: Namespace -> Name -> ImportSpec
- pattern IThingAll :: Name -> ImportSpec
- pattern IThingWith :: Name -> [CName] -> ImportSpec
- type Assoc = Assoc ()
- pattern AssocNone :: Assoc
- pattern AssocLeft :: Assoc
- pattern AssocRight :: Assoc
- type Decl = Decl ()
- pattern TypeDecl :: DeclHead -> Type -> Decl
- pattern TypeFamDecl :: DeclHead -> Maybe ResultSig -> Maybe InjectivityInfo -> Decl
- pattern ClosedTypeFamDecl :: DeclHead -> Maybe ResultSig -> Maybe InjectivityInfo -> [TypeEqn] -> Decl
- pattern DataDecl :: DataOrNew -> Maybe Context -> DeclHead -> [QualConDecl] -> [Deriving] -> Decl
- pattern GDataDecl :: DataOrNew -> Maybe Context -> DeclHead -> Maybe Kind -> [GadtDecl] -> [Deriving] -> Decl
- pattern DataFamDecl :: Maybe Context -> DeclHead -> Maybe ResultSig -> Decl
- pattern TypeInsDecl :: Type -> Type -> Decl
- pattern DataInsDecl :: DataOrNew -> Type -> [QualConDecl] -> [Deriving] -> Decl
- pattern GDataInsDecl :: DataOrNew -> Type -> Maybe Kind -> [GadtDecl] -> [Deriving] -> Decl
- pattern ClassDecl :: Maybe Context -> DeclHead -> [FunDep] -> Maybe [ClassDecl] -> Decl
- pattern InstDecl :: Maybe Overlap -> InstRule -> Maybe [InstDecl] -> Decl
- pattern DerivDecl :: Maybe DerivStrategy -> Maybe Overlap -> InstRule -> Decl
- pattern InfixDecl :: Assoc -> Maybe Int -> [Op] -> Decl
- pattern DefaultDecl :: [Type] -> Decl
- pattern SpliceDecl :: Exp -> Decl
- pattern TypeSig :: [Name] -> Type -> Decl
- pattern PatSynSig :: [Name] -> Maybe [TyVarBind] -> Maybe Context -> Maybe Context -> Type -> Decl
- pattern FunBind :: [Match] -> Decl
- pattern PatBind :: Pat -> Rhs -> Maybe Binds -> Decl
- pattern PatSyn :: Pat -> Pat -> PatternSynDirection -> Decl
- pattern ForImp :: CallConv -> Maybe Safety -> Maybe String -> Name -> Type -> Decl
- pattern ForExp :: CallConv -> Maybe String -> Name -> Type -> Decl
- pattern RulePragmaDecl :: [Rule] -> Decl
- pattern DeprPragmaDecl :: [([Name], String)] -> Decl
- pattern WarnPragmaDecl :: [([Name], String)] -> Decl
- pattern InlineSig :: Bool -> Maybe Activation -> QName -> Decl
- pattern InlineConlikeSig :: Maybe Activation -> QName -> Decl
- pattern SpecSig :: Maybe Activation -> QName -> [Type] -> Decl
- pattern SpecInlineSig :: Bool -> Maybe Activation -> QName -> [Type] -> Decl
- pattern InstSig :: InstRule -> Decl
- pattern AnnPragma :: Annotation -> Decl
- pattern MinimalPragma :: Maybe BooleanFormula -> Decl
- pattern RoleAnnotDecl :: QName -> [Role] -> Decl
- pattern CompletePragma :: [Name] -> Maybe QName -> Decl
- type PatternSynDirection = PatternSynDirection ()
- pattern Unidirectional :: PatternSynDirection
- pattern ImplicitBidirectional :: PatternSynDirection
- pattern ExplicitBidirectional :: [Decl] -> PatternSynDirection
- type TypeEqn = TypeEqn ()
- pattern TypeEqn :: Type -> Type -> TypeEqn
- type Annotation = Annotation ()
- pattern Ann :: Name -> Exp -> Annotation
- pattern TypeAnn :: Name -> Exp -> Annotation
- pattern ModuleAnn :: Exp -> Annotation
- type BooleanFormula = BooleanFormula ()
- pattern VarFormula :: Name -> BooleanFormula
- pattern AndFormula :: [BooleanFormula] -> BooleanFormula
- pattern OrFormula :: [BooleanFormula] -> BooleanFormula
- pattern ParenFormula :: BooleanFormula -> BooleanFormula
- type Role = Role ()
- pattern Nominal :: Role
- pattern Representational :: Role
- pattern Phantom :: Role
- pattern RoleWildcard :: Role
- type DataOrNew = DataOrNew ()
- pattern DataType :: DataOrNew
- pattern NewType :: DataOrNew
- type InjectivityInfo = InjectivityInfo ()
- pattern InjectivityInfo :: Name -> [Name] -> InjectivityInfo
- type ResultSig = ResultSig ()
- pattern KindSig :: Kind -> ResultSig
- pattern TyVarSig :: TyVarBind -> ResultSig
- type DeclHead = DeclHead ()
- pattern DHead :: Name -> DeclHead
- pattern DHInfix :: TyVarBind -> Name -> DeclHead
- pattern DHParen :: DeclHead -> DeclHead
- pattern DHApp :: DeclHead -> TyVarBind -> DeclHead
- type InstRule = InstRule ()
- pattern IRule :: Maybe [TyVarBind] -> Maybe Context -> InstHead -> InstRule
- pattern IParen :: InstRule -> InstRule
- type InstHead = InstHead ()
- pattern IHCon :: QName -> InstHead
- pattern IHInfix :: Type -> QName -> InstHead
- pattern IHParen :: InstHead -> InstHead
- pattern IHApp :: InstHead -> Type -> InstHead
- type Deriving = Deriving ()
- pattern Deriving :: Maybe DerivStrategy -> [InstRule] -> Deriving
- type DerivStrategy = DerivStrategy ()
- pattern DerivStock :: DerivStrategy
- pattern DerivAnyclass :: DerivStrategy
- pattern DerivNewtype :: DerivStrategy
- type Binds = Binds ()
- pattern BDecls :: [Decl] -> Binds
- pattern IPBinds :: [IPBind] -> Binds
- type IPBind = IPBind ()
- pattern IPBind :: IPName -> Exp -> IPBind
- type Match = Match ()
- pattern Match :: Name -> [Pat] -> Rhs -> Maybe Binds -> Match
- pattern InfixMatch :: Pat -> Name -> [Pat] -> Rhs -> Maybe Binds -> Match
- type QualConDecl = QualConDecl ()
- pattern QualConDecl :: Maybe [TyVarBind] -> Maybe Context -> ConDecl -> QualConDecl
- type ConDecl = ConDecl ()
- pattern ConDecl :: Name -> [Type] -> ConDecl
- pattern InfixConDecl :: Type -> Name -> Type -> ConDecl
- pattern RecDecl :: Name -> [FieldDecl] -> ConDecl
- type FieldDecl = FieldDecl ()
- pattern FieldDecl :: [Name] -> Type -> FieldDecl
- type GadtDecl = GadtDecl ()
- pattern GadtDecl :: Name -> Maybe [FieldDecl] -> Type -> GadtDecl
- type ClassDecl = ClassDecl ()
- pattern ClsDecl :: Decl -> ClassDecl
- pattern ClsDataFam :: Maybe Context -> DeclHead -> Maybe ResultSig -> ClassDecl
- pattern ClsTyFam :: DeclHead -> Maybe ResultSig -> Maybe InjectivityInfo -> ClassDecl
- pattern ClsTyDef :: TypeEqn -> ClassDecl
- pattern ClsDefSig :: Name -> Type -> ClassDecl
- type InstDecl = InstDecl ()
- pattern InsDecl :: Decl -> InstDecl
- pattern InsType :: Type -> Type -> InstDecl
- pattern InsData :: DataOrNew -> Type -> [QualConDecl] -> [Deriving] -> InstDecl
- pattern InsGData :: DataOrNew -> Type -> Maybe Kind -> [GadtDecl] -> [Deriving] -> InstDecl
- type BangType = BangType ()
- pattern BangedTy :: BangType
- pattern LazyTy :: BangType
- pattern NoStrictAnnot :: BangType
- type Unpackedness = Unpackedness ()
- pattern Unpack :: Unpackedness
- pattern NoUnpack :: Unpackedness
- pattern NoUnpackPragma :: Unpackedness
- type Rhs = Rhs ()
- pattern UnGuardedRhs :: Exp -> Rhs
- pattern GuardedRhss :: [GuardedRhs] -> Rhs
- type GuardedRhs = GuardedRhs ()
- pattern GuardedRhs :: [Stmt] -> Exp -> GuardedRhs
- type Type = Type ()
- pattern TyForall :: Maybe [TyVarBind] -> Maybe Context -> Type -> Type
- pattern TyFun :: Type -> Type -> Type
- pattern TyTuple :: Boxed -> [Type] -> Type
- pattern TyUnboxedSum :: [Type] -> Type
- pattern TyList :: Type -> Type
- pattern TyParArray :: Type -> Type
- pattern TyApp :: Type -> Type -> Type
- pattern TyVar :: Name -> Type
- pattern TyCon :: QName -> Type
- pattern TyParen :: Type -> Type
- pattern TyInfix :: Type -> MaybePromotedName -> Type -> Type
- pattern TyKind :: Type -> Kind -> Type
- pattern TyPromoted :: Promoted -> Type
- pattern TyEquals :: Type -> Type -> Type
- pattern TySplice :: Splice -> Type
- pattern TyBang :: BangType -> Unpackedness -> Type -> Type
- pattern TyWildCard :: Maybe Name -> Type
- pattern TyQuasiQuote :: String -> String -> Type
- type MaybePromotedName = MaybePromotedName ()
- pattern PromotedName :: QName -> MaybePromotedName
- pattern UnpromotedName :: QName -> MaybePromotedName
- type Promoted = Promoted ()
- pattern PromotedInteger :: Integer -> String -> Promoted
- pattern PromotedString :: String -> String -> Promoted
- pattern PromotedCon :: Bool -> QName -> Promoted
- pattern PromotedList :: Bool -> [Type] -> Promoted
- pattern PromotedTuple :: [Type] -> Promoted
- pattern PromotedUnit :: Promoted
- type TyVarBind = TyVarBind ()
- pattern KindedVar :: Name -> Kind -> TyVarBind
- pattern UnkindedVar :: Name -> TyVarBind
- type Kind = Kind ()
- pattern KindStar :: Kind
- pattern KindFn :: Kind -> Kind -> Kind
- pattern KindParen :: Kind -> Kind
- pattern KindVar :: QName -> Kind
- pattern KindApp :: Kind -> Kind -> Kind
- pattern KindTuple :: [Kind] -> Kind
- pattern KindList :: Kind -> Kind
- type FunDep = FunDep ()
- pattern FunDep :: [Name] -> [Name] -> FunDep
- type Context = Context ()
- pattern CxSingle :: Asst -> Context
- pattern CxTuple :: [Asst] -> Context
- pattern CxEmpty :: Context
- type Asst = Asst ()
- pattern ClassA :: QName -> [Type] -> Asst
- pattern AppA :: Name -> [Type] -> Asst
- pattern InfixA :: Type -> QName -> Type -> Asst
- pattern IParam :: IPName -> Type -> Asst
- pattern EqualP :: Type -> Type -> Asst
- pattern ParenA :: Asst -> Asst
- pattern WildCardA :: Maybe Name -> Asst
- type Literal = Literal ()
- pattern Char :: Char -> Literal
- charL :: Char -> Literal
- pattern String :: String -> Literal
- stringL :: String -> Literal
- pattern Int :: Integer -> Literal
- intL :: Integer -> Literal
- pattern Frac :: Rational -> Literal
- fracL :: Rational -> Literal
- pattern PrimInt :: Integer -> Literal
- primIntL :: Integer -> Literal
- pattern PrimWord :: Integer -> Literal
- primWordL :: Integer -> Literal
- pattern PrimFloat :: Rational -> Literal
- primFloatL :: Rational -> Literal
- pattern PrimDouble :: Rational -> Literal
- primDoubleL :: Rational -> Literal
- pattern PrimChar :: Char -> Literal
- primCharL :: Char -> Literal
- pattern PrimString :: String -> Literal
- primStringL :: String -> Literal
- type Sign = Sign ()
- pattern Signless :: Sign
- pattern Negative :: Sign
- type Exp = Exp ()
- pattern Var :: QName -> Exp
- pattern OverloadedLabel :: String -> Exp
- pattern IPVar :: IPName -> Exp
- pattern Con :: QName -> Exp
- pattern Lit :: Literal -> Exp
- pattern InfixApp :: Exp -> QOp -> Exp -> Exp
- pattern App :: Exp -> Exp -> Exp
- pattern NegApp :: Exp -> Exp
- pattern Lambda :: [Pat] -> Exp -> Exp
- pattern Let :: Binds -> Exp -> Exp
- pattern If :: Exp -> Exp -> Exp -> Exp
- pattern MultiIf :: [GuardedRhs] -> Exp
- pattern Case :: Exp -> [Alt] -> Exp
- pattern Do :: [Stmt] -> Exp
- pattern MDo :: [Stmt] -> Exp
- pattern Tuple :: Boxed -> [Exp] -> Exp
- pattern UnboxedSum :: Int -> Int -> Exp -> Exp
- pattern TupleSection :: Boxed -> [Maybe Exp] -> Exp
- pattern List :: [Exp] -> Exp
- pattern ParArray :: [Exp] -> Exp
- pattern Paren :: Exp -> Exp
- pattern LeftSection :: Exp -> QOp -> Exp
- pattern RightSection :: QOp -> Exp -> Exp
- pattern RecConstr :: QName -> [FieldUpdate] -> Exp
- pattern RecUpdate :: Exp -> [FieldUpdate] -> Exp
- pattern EnumFrom :: Exp -> Exp
- pattern EnumFromTo :: Exp -> Exp -> Exp
- pattern EnumFromThen :: Exp -> Exp -> Exp
- pattern EnumFromThenTo :: Exp -> Exp -> Exp -> Exp
- pattern ParArrayFromTo :: Exp -> Exp -> Exp
- pattern ParArrayFromThenTo :: Exp -> Exp -> Exp -> Exp
- pattern ListComp :: Exp -> [QualStmt] -> Exp
- pattern ParComp :: Exp -> [[QualStmt]] -> Exp
- pattern ParArrayComp :: Exp -> [[QualStmt]] -> Exp
- pattern ExpTypeSig :: Exp -> Type -> Exp
- pattern VarQuote :: QName -> Exp
- pattern TypQuote :: QName -> Exp
- pattern BracketExp :: Bracket -> Exp
- pattern SpliceExp :: Splice -> Exp
- pattern QuasiQuote :: String -> String -> Exp
- pattern TypeApp :: Type -> Exp
- pattern XTag :: XName -> [XAttr] -> Maybe Exp -> [Exp] -> Exp
- pattern XETag :: XName -> [XAttr] -> Maybe Exp -> Exp
- pattern XPcdata :: String -> Exp
- pattern XExpTag :: Exp -> Exp
- pattern XChildTag :: [Exp] -> Exp
- pattern CorePragma :: String -> Exp -> Exp
- pattern SCCPragma :: String -> Exp -> Exp
- pattern GenPragma :: String -> (Int, Int) -> (Int, Int) -> Exp -> Exp
- pattern Proc :: Pat -> Exp -> Exp
- pattern LeftArrApp :: Exp -> Exp -> Exp
- pattern RightArrApp :: Exp -> Exp -> Exp
- pattern LeftArrHighApp :: Exp -> Exp -> Exp
- pattern RightArrHighApp :: Exp -> Exp -> Exp
- pattern LCase :: [Alt] -> Exp
- type XName = XName ()
- pattern XName :: String -> XName
- pattern XDomName :: String -> String -> XName
- type XAttr = XAttr ()
- pattern XAttr :: XName -> Exp -> XAttr
- type Bracket = Bracket ()
- pattern ExpBracket :: Exp -> Bracket
- pattern PatBracket :: Pat -> Bracket
- pattern TypeBracket :: Type -> Bracket
- pattern DeclBracket :: [Decl] -> Bracket
- type Splice = Splice ()
- pattern IdSplice :: String -> Splice
- pattern ParenSplice :: Exp -> Splice
- type Safety = Safety ()
- pattern PlayRisky :: Safety
- pattern PlaySafe :: Bool -> Safety
- pattern PlayInterruptible :: Safety
- type CallConv = CallConv ()
- pattern StdCall :: CallConv
- pattern CCall :: CallConv
- pattern CPlusPlus :: CallConv
- pattern DotNet :: CallConv
- pattern Jvm :: CallConv
- pattern Js :: CallConv
- pattern JavaScript :: CallConv
- pattern CApi :: CallConv
- type ModulePragma = ModulePragma ()
- pattern LanguagePragma :: [Name] -> ModulePragma
- pattern OptionsPragma :: Maybe Tool -> String -> ModulePragma
- pattern AnnModulePragma :: Annotation -> ModulePragma
- type Overlap = Overlap ()
- pattern NoOverlap :: Overlap
- pattern Overlap :: Overlap
- pattern Overlapping :: Overlap
- pattern Overlaps :: Overlap
- pattern Overlappable :: Overlap
- pattern Incoherent :: Overlap
- type Activation = Activation ()
- pattern ActiveFrom :: Int -> Activation
- pattern ActiveUntil :: Int -> Activation
- type Rule = Rule ()
- pattern Rule :: String -> Maybe Activation -> Maybe [RuleVar] -> Exp -> Exp -> Rule
- type RuleVar = RuleVar ()
- pattern RuleVar :: Name -> RuleVar
- pattern TypedRuleVar :: Name -> Type -> RuleVar
- type WarningText = WarningText ()
- pattern DeprText :: String -> WarningText
- pattern WarnText :: String -> WarningText
- type Pat = Pat ()
- pattern PVar :: Name -> Pat
- pattern PLit :: Sign -> Literal -> Pat
- pattern PNPlusK :: Name -> Integer -> Pat
- pattern PInfixApp :: Pat -> QName -> Pat -> Pat
- pattern PApp :: QName -> [Pat] -> Pat
- pattern PTuple :: Boxed -> [Pat] -> Pat
- pattern PUnboxedSum :: Int -> Int -> Pat -> Pat
- pattern PList :: [Pat] -> Pat
- pattern PParen :: Pat -> Pat
- pattern PRec :: QName -> [PatField] -> Pat
- pattern PAsPat :: Name -> Pat -> Pat
- pattern PWildCard :: Pat
- pattern PIrrPat :: Pat -> Pat
- pattern PatTypeSig :: Pat -> Type -> Pat
- pattern PViewPat :: Exp -> Pat -> Pat
- pattern PRPat :: [RPat] -> Pat
- pattern PXTag :: XName -> [PXAttr] -> Maybe Pat -> [Pat] -> Pat
- pattern PXETag :: XName -> [PXAttr] -> Maybe Pat -> Pat
- pattern PXPcdata :: String -> Pat
- pattern PXPatTag :: Pat -> Pat
- pattern PXRPats :: [RPat] -> Pat
- pattern PSplice :: Splice -> Pat
- pattern PQuasiQuote :: String -> String -> Pat
- pattern PBangPat :: Pat -> Pat
- type PXAttr = PXAttr ()
- pattern PXAttr :: XName -> Pat -> PXAttr
- type RPatOp = RPatOp ()
- pattern RPStar :: RPatOp
- pattern RPStarG :: RPatOp
- pattern RPPlus :: RPatOp
- pattern RPPlusG :: RPatOp
- pattern RPOpt :: RPatOp
- pattern RPOptG :: RPatOp
- type RPat = RPat ()
- pattern RPOp :: RPat -> RPatOp -> RPat
- pattern RPEither :: RPat -> RPat -> RPat
- pattern RPSeq :: [RPat] -> RPat
- pattern RPGuard :: Pat -> [Stmt] -> RPat
- pattern RPCAs :: Name -> RPat -> RPat
- pattern RPAs :: Name -> RPat -> RPat
- pattern RPParen :: RPat -> RPat
- pattern RPPat :: Pat -> RPat
- type PatField = PatField ()
- pattern PFieldPat :: QName -> Pat -> PatField
- pattern PFieldPun :: QName -> PatField
- pattern PFieldWildcard :: PatField
- type Stmt = Stmt ()
- pattern Generator :: Pat -> Exp -> Stmt
- pattern Qualifier :: Exp -> Stmt
- pattern LetStmt :: Binds -> Stmt
- pattern RecStmt :: [Stmt] -> Stmt
- type QualStmt = QualStmt ()
- pattern QualStmt :: Stmt -> QualStmt
- pattern ThenTrans :: Exp -> QualStmt
- pattern ThenBy :: Exp -> Exp -> QualStmt
- pattern GroupBy :: Exp -> QualStmt
- pattern GroupUsing :: Exp -> QualStmt
- pattern GroupByUsing :: Exp -> Exp -> QualStmt
- type FieldUpdate = FieldUpdate ()
- pattern FieldUpdate :: QName -> Exp -> FieldUpdate
- pattern FieldPun :: QName -> FieldUpdate
- pattern FieldWildcard :: FieldUpdate
- type Alt = Alt ()
- pattern Alt :: Pat -> Rhs -> Maybe Binds -> Alt
- prelude_mod :: ModuleName
- main_mod :: ModuleName
- main_name :: Name
- unit_con_name :: QName
- tuple_con_name :: Boxed -> Int -> QName
- list_cons_name :: QName
- unboxed_singleton_con_name :: QName
- unit_con :: Exp
- tuple_con :: Boxed -> Int -> Exp
- unboxed_singleton_con :: Exp
- as_name :: Name
- qualified_name :: Name
- hiding_name :: Name
- minus_name :: Name
- bang_name :: Name
- dot_name :: Name
- star_name :: Name
- hole_name :: QName
- export_name :: Name
- safe_name :: Name
- unsafe_name :: Name
- interruptible_name :: Name
- threadsafe_name :: Name
- stdcall_name :: Name
- ccall_name :: Name
- cplusplus_name :: Name
- dotnet_name :: Name
- jvm_name :: Name
- js_name :: Name
- javascript_name :: Name
- capi_name :: Name
- forall_name :: Name
- family_name :: Name
- role_name :: Name
- stock_name :: Name
- anyclass_name :: Name
- unit_tycon_name :: QName
- fun_tycon_name :: QName
- list_tycon_name :: QName
- unboxed_singleton_tycon_name :: QName
- tuple_tycon_name :: Boxed -> Int -> QName
- unit_tycon :: Type
- fun_tycon :: Type
- list_tycon :: Type
- unboxed_singleton_tycon :: Type
- tuple_tycon :: Boxed -> Int -> Type
- module Language.Haskell.Exts.Syntax
Datatypes and Constructors
ModuleName
type ModuleName = ModuleName () Source #
pattern ModuleName :: String -> ModuleName Source #
SpecialCon
type SpecialCon = SpecialCon () Source #
pattern UnitCon :: SpecialCon Source #
pattern ListCon :: SpecialCon Source #
pattern FunCon :: SpecialCon Source #
pattern Cons :: SpecialCon Source #
pattern UnboxedSingleCon :: SpecialCon Source #
pattern ExprHole :: SpecialCon Source #
QName
pattern Special :: SpecialCon -> QName Source #
Name
IPName
QOp
Op
CName
Module
pattern Module :: Maybe ModuleHead -> [ModulePragma] -> [ImportDecl] -> [Decl] -> Module Source #
pattern XmlPage :: ModuleName -> [ModulePragma] -> XName -> [XAttr] -> Maybe Exp -> [Exp] -> Module Source #
pattern XmlHybrid :: Maybe ModuleHead -> [ModulePragma] -> [ImportDecl] -> [Decl] -> XName -> [XAttr] -> Maybe Exp -> [Exp] -> Module Source #
ModuleHead
type ModuleHead = ModuleHead () Source #
pattern ModuleHead :: ModuleName -> Maybe WarningText -> Maybe ExportSpecList -> ModuleHead Source #
ExportSpecList
type ExportSpecList = ExportSpecList () Source #
pattern ExportSpecList :: [ExportSpec] -> ExportSpecList Source #
ExportSpec
type ExportSpec = ExportSpec () Source #
pattern EVar :: QName -> ExportSpec Source #
pattern EThingWith :: EWildcard -> QName -> [CName] -> ExportSpec Source #
pattern EModuleContents :: ModuleName -> ExportSpec Source #
EWildcard
pattern NoWildcard :: EWildcard Source #
Namespace
pattern NoNamespace :: Namespace Source #
pattern TypeNamespace :: Namespace Source #
pattern PatternNamespace :: Namespace Source #
ImportDecl
type ImportDecl = ImportDecl () Source #
pattern ImportDecl :: ModuleName () -> Bool -> Bool -> Bool -> Maybe String -> Maybe (ModuleName ()) -> Maybe (ImportSpecList ()) -> ImportDecl Source #
Note, this is originally a record constructor, and we use a pattern record synonym for ghc-8.0. But for earlier ghc versions, ImportDecl
is a plain pattern synonym, and the selectors are exported as functions.
ImportSpecList
type ImportSpecList = ImportSpecList () Source #
pattern ImportSpecList :: Bool -> [ImportSpec] -> ImportSpecList Source #
ImportSpec
type ImportSpec = ImportSpec () Source #
pattern IVar :: Name -> ImportSpec Source #
pattern IThingAll :: Name -> ImportSpec Source #
pattern IThingWith :: Name -> [CName] -> ImportSpec Source #
Assoc
pattern AssocRight :: Assoc Source #
Decl
pattern TypeFamDecl :: DeclHead -> Maybe ResultSig -> Maybe InjectivityInfo -> Decl Source #
pattern ClosedTypeFamDecl :: DeclHead -> Maybe ResultSig -> Maybe InjectivityInfo -> [TypeEqn] -> Decl Source #
pattern DataDecl :: DataOrNew -> Maybe Context -> DeclHead -> [QualConDecl] -> [Deriving] -> Decl Source #
pattern GDataDecl :: DataOrNew -> Maybe Context -> DeclHead -> Maybe Kind -> [GadtDecl] -> [Deriving] -> Decl Source #
pattern DataInsDecl :: DataOrNew -> Type -> [QualConDecl] -> [Deriving] -> Decl Source #
pattern GDataInsDecl :: DataOrNew -> Type -> Maybe Kind -> [GadtDecl] -> [Deriving] -> Decl Source #
pattern DefaultDecl :: [Type] -> Decl Source #
pattern SpliceDecl :: Exp -> Decl Source #
pattern PatSynSig :: [Name] -> Maybe [TyVarBind] -> Maybe Context -> Maybe Context -> Type -> Decl Source #
pattern RulePragmaDecl :: [Rule] -> Decl Source #
pattern InlineConlikeSig :: Maybe Activation -> QName -> Decl Source #
pattern SpecInlineSig :: Bool -> Maybe Activation -> QName -> [Type] -> Decl Source #
pattern AnnPragma :: Annotation -> Decl Source #
pattern MinimalPragma :: Maybe BooleanFormula -> Decl Source #
PatternSynDirection
type PatternSynDirection = PatternSynDirection () Source #
pattern Unidirectional :: PatternSynDirection Source #
pattern ImplicitBidirectional :: PatternSynDirection Source #
pattern ExplicitBidirectional :: [Decl] -> PatternSynDirection Source #
TypeEqn
Annotation
type Annotation = Annotation () Source #
pattern ModuleAnn :: Exp -> Annotation Source #
BooleanFormula
type BooleanFormula = BooleanFormula () Source #
pattern VarFormula :: Name -> BooleanFormula Source #
pattern AndFormula :: [BooleanFormula] -> BooleanFormula Source #
pattern OrFormula :: [BooleanFormula] -> BooleanFormula Source #
pattern ParenFormula :: BooleanFormula -> BooleanFormula Source #
Role
pattern Representational :: Role Source #
pattern RoleWildcard :: Role Source #
DataOrNew
InjectivityInfo
type InjectivityInfo = InjectivityInfo () Source #
pattern InjectivityInfo :: Name -> [Name] -> InjectivityInfo Source #
ResultSig
DeclHead
InstRule
InstHead
Deriving
DerivStrategy
type DerivStrategy = DerivStrategy () Source #
pattern DerivStock :: DerivStrategy Source #
pattern DerivAnyclass :: DerivStrategy Source #
pattern DerivNewtype :: DerivStrategy Source #
Binds
IPBind
Match
QualConDecl
type QualConDecl = QualConDecl () Source #
pattern QualConDecl :: Maybe [TyVarBind] -> Maybe Context -> ConDecl -> QualConDecl Source #
ConDecl
FieldDecl
GadtDecl
ClassDecl
InstDecl
pattern InsGData :: DataOrNew -> Type -> Maybe Kind -> [GadtDecl] -> [Deriving] -> InstDecl Source #
BangType
pattern NoStrictAnnot :: BangType Source #
Unpackedness
type Unpackedness = Unpackedness () Source #
pattern Unpack :: Unpackedness Source #
pattern NoUnpack :: Unpackedness Source #
pattern NoUnpackPragma :: Unpackedness Source #
Rhs
pattern UnGuardedRhs :: Exp -> Rhs Source #
pattern GuardedRhss :: [GuardedRhs] -> Rhs Source #
GuardedRhs
type GuardedRhs = GuardedRhs () Source #
pattern GuardedRhs :: [Stmt] -> Exp -> GuardedRhs Source #
Type
pattern TyUnboxedSum :: [Type] -> Type Source #
pattern TyParArray :: Type -> Type Source #
pattern TyPromoted :: Promoted -> Type Source #
MaybePromotedName
type MaybePromotedName = MaybePromotedName () Source #
pattern PromotedName :: QName -> MaybePromotedName Source #
pattern UnpromotedName :: QName -> MaybePromotedName Source #
Promoted
pattern PromotedTuple :: [Type] -> Promoted Source #
pattern PromotedUnit :: Promoted Source #
TyVarBind
pattern UnkindedVar :: Name -> TyVarBind Source #
Kind
FunDep
Context
Asst
Literal
primFloatL :: Rational -> Literal Source #
pattern PrimDouble :: Rational -> Literal Source #
primDoubleL :: Rational -> Literal Source #
pattern PrimString :: String -> Literal Source #
primStringL :: String -> Literal Source #
Sign
Exp
pattern OverloadedLabel :: String -> Exp Source #
pattern MultiIf :: [GuardedRhs] -> Exp Source #
pattern BracketExp :: Bracket -> Exp Source #
XName
XAttr
Bracket
pattern ExpBracket :: Exp -> Bracket Source #
pattern PatBracket :: Pat -> Bracket Source #
pattern TypeBracket :: Type -> Bracket Source #
pattern DeclBracket :: [Decl] -> Bracket Source #
Splice
pattern ParenSplice :: Exp -> Splice Source #
Safety
pattern PlayInterruptible :: Safety Source #
CallConv
pattern JavaScript :: CallConv Source #
ModulePragma
type ModulePragma = ModulePragma () Source #
pattern LanguagePragma :: [Name] -> ModulePragma Source #
pattern OptionsPragma :: Maybe Tool -> String -> ModulePragma Source #
pattern AnnModulePragma :: Annotation -> ModulePragma Source #
Overlap
pattern Overlapping :: Overlap Source #
pattern Overlappable :: Overlap Source #
pattern Incoherent :: Overlap Source #
Activation
type Activation = Activation () Source #
pattern ActiveFrom :: Int -> Activation Source #
pattern ActiveUntil :: Int -> Activation Source #
Rule
RuleVar
WarningText
type WarningText = WarningText () Source #
pattern DeprText :: String -> WarningText Source #
pattern WarnText :: String -> WarningText Source #
Pat
PXAttr
RPatOp
RPat
PatField
pattern PFieldWildcard :: PatField Source #
Stmt
QualStmt
pattern GroupUsing :: Exp -> QualStmt Source #
FieldUpdate
type FieldUpdate = FieldUpdate () Source #
pattern FieldUpdate :: QName -> Exp -> FieldUpdate Source #
pattern FieldPun :: QName -> FieldUpdate Source #
pattern FieldWildcard :: FieldUpdate Source #
Alt
Functions
hiding_name :: Name Source #
minus_name :: Name Source #
export_name :: Name Source #
unsafe_name :: Name Source #
stdcall_name :: Name Source #
ccall_name :: Name Source #
dotnet_name :: Name Source #
forall_name :: Name Source #
family_name :: Name Source #
stock_name :: Name Source #
anyclass_name :: Name Source #
unit_tycon :: Type Source #
list_tycon :: Type Source #
module Language.Haskell.Exts.Syntax