concat-plugin-0.3.0.0: GHC plugin for compiling to categories
Safe HaskellSafe-Inferred
LanguageHaskell2010

ConCat.Plugin

Description

GHC plugin converting to CCC form.

Synopsis

Documentation

pattern FunTy' :: Type -> Type -> Type Source #

type Rewrite a = a -> Maybe a Source #

trying :: (String -> SDoc -> Bool -> Bool) -> String -> a -> Bool Source #

type Cat = Type Source #

pattern Coerce :: Cat -> Type -> Type -> CoreExpr Source #

pattern Compose :: Cat -> Type -> Type -> Type -> CoreExpr -> CoreExpr -> CoreExpr Source #

pattern CatVar :: String -> Id Source #

data Ops Source #

Constructors

Ops 

Fields

module name for categorical counterpart (always catModule now)

categorical operation name

type arguments to cat op

pp :: Outputable a => a -> String Source #

qualifiedName :: Name -> String Source #

Get the fully qualified name from a Name.

onHead :: Unop a -> Unop [a] Source #

(<+) :: Binop (a -> Maybe b) infixl 3 Source #

idOccs :: Bool -> Id -> CoreExpr -> Int Source #

Number of occurrences of a given Id in an expression. Gives a large value if the Id appears under a lambda.

altRhs :: Alt b -> Expr b Source #

altVars :: Alt b -> [b] Source #

everywhereM' :: Monad m => GenericM m -> GenericM m Source #

Monadic variation on everywhere (bottom-up) everywhereM :: Monad m => GenericM m -> GenericM m everywhereM f = f <=< gmapM (everywhereM2 f)

Monadic variation on everywhere' (top-down)