haskell-tools-rewrite-1.0.1.1: Facilities for generating new parts of the Haskell-Tools AST

Safe HaskellNone
LanguageHaskell2010

Language.Haskell.Tools.Rewrite.Match.Types

Contents

Description

UPattern matching on type-level AST fragments for refactorings.

Synopsis

Types

pattern ForallType :: TyVarList -> Type -> Type Source #

Forall types ( forall x y . type )

pattern CtxType :: Context -> Type -> Type Source #

Type with a context ( C a => type )

pattern FunctionType :: Type -> Type -> Type Source #

Function types ( a -> b )

pattern TupleType :: TypeList -> Type Source #

Tuple types ( (a,b) )

pattern UnboxedTupleType :: TypeList -> Type Source #

Unboxed tuple types ( (#a,b#) )

pattern ListType :: Type -> Type Source #

List type with special syntax ( [a] )

pattern ParArrayType :: Type -> Type Source #

Parallel array type ( [:a:] )

pattern TypeApp :: Type -> Type -> Type Source #

Type application ( F a )

pattern InfixTypeApp :: Type -> Operator -> Type -> Type Source #

Infix type constructor ( (a <: b) )

pattern ParenType :: Type -> Type Source #

Type surrounded by parentheses ( (T a) )

pattern VarType :: Name -> Type Source #

Type variable or constructor ( a )

pattern KindedType :: Type -> Kind -> Type Source #

Type with explicit kind signature ( a :: * )

pattern BangType :: Type -> Type Source #

Strict type marked with !.

pattern LazyType :: Type -> Type Source #

Lazy type marked with ~. (Should only be used if Strict or StrictData language extension is used)

pattern UnpackType :: Type -> Type Source #

Strict type marked with UNPACK pragma. (Usually contains the bang mark.)

pattern NoUnpackType :: Type -> Type Source #

Strict type marked with NOUNPACK pragma. (Usually contains the bang mark.)

pattern WildcardType :: Type Source #

A wildcard type ( _ ) with -XPartialTypeSignatures

pattern NamedWildcardType :: Name -> Type Source #

A named wildcard type ( _t ) with -XPartialTypeSignatures

pattern SpliceType :: Splice -> Type Source #

A Template Haskell splice type ( $(genType) ).

pattern QuasiQuoteType :: QuasiQuote -> Type Source #

A Template Haskell splice type ( $(genType) ).

pattern PromotedIntType :: Integer -> Type Source #

Numeric value promoted to the type level.

pattern PromotedStringType :: String -> Type Source #

String value promoted to the type level.

pattern PromotedConType :: Name -> Type Source #

A data constructor value promoted to the type level.

pattern PromotedListType :: TypeList -> Type Source #

A list of elements as a type.

pattern PromotedTupleType :: TypeList -> Type Source #

A tuple of elements as a type.

pattern PromotedUnitType :: Type Source #

Kind of the unit value ().

Type variable

pattern TyVarDecl :: Name -> TyVar Source #

Type variable declaration

pattern KindedTyVarDecl :: Name -> Kind -> TyVar Source #

Kinded type variable declaration ( v :: * )

Contexts

pattern Context :: Assertion -> Context Source #

A context of assertions ( C a => ... )

Assertions

pattern ClassAssert :: Name -> TypeList -> Assertion Source #

Class assertion (Cls x)

pattern InfixAssert :: Type -> Operator -> Type -> Assertion Source #

Infix class assertion, also contains type equations ( a ~ X y )

pattern ImplicitAssert :: Name -> Type -> Assertion Source #

Assertion for implicit parameter binding ( ?cmp :: a -> a -> Bool )

pattern TupleAssert :: [Assertion] -> Assertion Source #

A list of assertions ( (Eq a, Show a) )