| Safe Haskell | None |
|---|---|
| Language | Haskell2010 |
Control.Monad.Foil.TH.MkInstancesFoil
Documentation
Arguments
| :: Name | Type name for raw terms. |
| -> Name | Type name for raw variable identifiers. |
| -> Name | Type name for raw scoped terms. |
| -> Name | Type name for raw patterns. |
| -> Q [Dec] |
Generate Sinkable and CoSinkable instances.
Since: 0.0.1
mkCoSinkableFoilPattern Source #
Generate the CoSinkable instance of the pattern type that
mkFoilPattern generates from a raw
pattern type, given the raw types of identifiers and patterns.
deriveCoSinkable takes the scope-safe pattern type itself.
Up to 0.5.0, this was deriveCoSinkable.
Since: 0.6.0
deriveCoSinkable :: Name -> Q [Dec] Source #
Generate the CoSinkable instance of a scope-safe pattern type.
mkCoSinkableFoilPattern takes the raw pattern type instead.
data Pat (n :: S) (l :: S) where PatVar :: NameBinder n l -> Pat n l PatPair :: NameBinder n i -> NameBinder i l -> Pat n l deriveCoSinkable ''Pat
A field is a NameBinder, a nested pattern, or a payload that
mentions no scope. A payload indexed by a scope needs a hand-written
instance (see transportPayload).
Since: 0.6.0